Commit graph

156 commits

Author SHA1 Message Date
ehouse
ae0b8211fe Toward a palm build whose only comms mode is relay (no IR, which was
always default.)  Plays half a robot-robot game via relay as client --
that is, debugging remains.
2009-02-17 05:54:28 +00:00
ehouse
62d247ee49 Helps to compile platforms too before checking in... 2009-02-01 16:20:18 +00:00
ehouse
7556ecf49f Make it possible to run same binary against relay with relay heartbeat
and direct with comms heartbeat.  This mostly means changing ifdefs.
2009-02-01 15:50:58 +00:00
ehouse
e20d57e6fb finish rem: changes and fix crash: show Remaining tiles dialog and draw focussed 2008-11-19 05:08:57 +00:00
ehouse
181e880d8d Add listeners to model so board can be notified whenever dictionary
changes.  Pass dict into draw via new API, removing it from the
draw_begin calls.
2008-09-05 12:11:37 +00:00
ehouse
865435b785 add new warning message 2008-07-28 05:01:03 +00:00
ehouse
95c6182b3c remove unused variable 2008-07-17 05:01:24 +00:00
ehouse
8a6df572ae add some consts. 2008-05-06 12:49:37 +00:00
ehouse
72457bf28c add ability to scroll the board by dragging it. add new method
util_altKeyDown to allow user to choose between scrolling board and
dragging the hint rect when both are possible.  add adjustYOffset;
make it and board_setYOffset more tolerant of out-of-bounds inputs and
use that to simplify calling code.
2008-04-08 03:55:53 +00:00
ehouse
d7cfc5acdf Error code used with method to check consistency of BT address. 2008-01-07 01:18:51 +00:00
ehouse
a9d1697c7b Update to use modified newg_store 2008-01-05 16:37:49 +00:00
ehouse
93cb20214e log date on startup; don't always put up about dialog on first boot; remove excessive logging 2008-01-02 01:45:58 +00:00
ehouse
ef8a5d0b11 Make initial value of confirmBTConnect true. 2007-12-15 18:55:32 +00:00
ehouse
84b707990e Substitute name of remote host into request for connection
initialization confirmation.
2007-12-15 07:22:12 +00:00
ehouse
c8bbfc5432 Instead of warning user on failure to connect via BT, add preference
to allow user to confirm before every attempt.  Users will learn to
set this when T650s are in the mix.  Save a new preference, and up the
stream version.  Up beta version.  Add the preference both to the prefs
dialog and to the bluetooth connection (for guest) dialog, with both
impacting the same field in gamePrefs.
2007-12-14 03:38:55 +00:00
ehouse
d482a9d57b fix bug using same string and code to warn and to reject phonies. 2007-12-14 03:21:46 +00:00
ehouse
fbc2535979 Change Resend menu text, and to make it clearer put up an error message when it's used in a standalone game. 2007-12-12 04:23:42 +00:00
ehouse
3dc9f327f8 Substitute French translations of new BT-related strings; since this
results in overlapping buttons, add code to space them evenly across
window.
2007-12-11 04:36:50 +00:00
ehouse
63ccaed46e cleanup; replace a bunch of EvtAddEventToQueue calls with
postEmptyEvent; pass transport type with incoming packets so they can
be rejected if not on expected channel (to stop IR, which is always
on, from injecting into a BT game); do BT work and fire timers even
when menu is down; don't let robot run until after board is drawn for
the first time; on startup, don't let robot run until after board is
drawn once.  Up version to b3.
2007-12-09 01:59:15 +00:00
ehouse
c72d0fec65 Fix crash on restart when app had been exited with some form other
than main on top.  focusOwner was saved based on front form but on
startup I tried to set it in the main form.  This will need to be
merged into a branch based on the 4.2.1 release for a 4.2.1.
2007-12-08 21:04:44 +00:00
ehouse
693eeb6863 Remove unused code and constants; fix to compile with relay; don't
show connection type dialog unless more than IR is available and
supported, and then build the dropdown dynamically based on what's
compiled-in and available on the device.  This means you don't see the
BT option at all if you don't have BT.
2007-12-08 18:11:42 +00:00
ehouse
f70bdb54ae Remove excessive focus logging; fix timer bug for BT by posting event so EvtGetEvent can exit 2007-12-06 05:26:44 +00:00
ehouse
c2ad749f99 Change util function to use signed type; other cleanup to compile with various features. 2007-12-05 06:28:51 +00:00
ehouse
6ed33b8914 Log BT lib version -- toward refusing to run or alerting user of broken Treo650 (version 1). 2007-12-03 01:18:59 +00:00
ehouse
b527110379 replace all __FUNCTION__ with __func__ 2007-12-02 19:13:25 +00:00
ehouse
321acd1d42 Add and set a compile-time option so comms will set a periodic timer
and use it to send and check for heartbeats over any transport.
Caller must supply a reset proc which is called when heartbeat hasn't
been received in too long.  No changes required to comms protocol, but
that means the heartbeat interval is fixed at compile time: can't be
negotiated, and the two ends had better agree.  Currently tested with
linux host and PalmOS guest, where only the first heartbeat failure is
recovered from.  So there's some debugging to be done still.
2007-11-18 23:43:27 +00:00
ehouse
d1054a52ff Use a single general-purpose callback passed into palm_bt_doWork where
it's needed, removing those passed into _init and _send.  When client
is unable to connect to host, raise alert to user and give choice to
continue trying.  Clear 'suspendBT' flag when user manually resends or
opens different game.  Currently this happens only on guest's failure
to find registered SDP; should also extend to remote device not
running at all and to host failure to send to guest.
2007-11-07 13:40:56 +00:00
ehouse
b289d291f9 move LOG_OFFSET 2007-09-30 17:22:38 +00:00
ehouse
28dc5c7d38 If we get keyUp event, override earlier determination that this device doesn't get them. This works around Tungsten double-key bug. Better fix will be to use the right FtrGet constants to set generatesKeyUp. 2007-08-22 02:36:13 +00:00
ehouse
47c3b0f7bd add fnav resource for password dialog, and use it if device has fiveway.
Otherwise use FrmSetFocus.  This works around a bug where key event that
leaks through from parent dialog dismisses dialog (whereupon another comes
up, and eventually cursor is left flashing on parent.)
2007-06-18 13:21:36 +00:00
ehouse
a79d36a150 Use a timer to avoid trying to get an ACL connection too frequetly.
This seems to trigger crash Treo650s far less often than constantly
retrying.
2007-05-26 22:51:25 +00:00
ehouse
5878ea6018 type name change only 2007-05-26 14:14:01 +00:00
ehouse
e891a26756 substitute macro for common sizeof(x)/sizeof(x[0]) pattern; no generated code change 2007-05-26 14:03:07 +00:00
ehouse
41b81f463e Hide tray on turn transitions when more than one non-robot local player present in game. 2007-05-20 20:46:29 +00:00
ehouse
b78dfc9d61 Up version for ship; build LocalizedStrIncludes.h per-platform;
include language in all platform obj directory names
2007-05-13 21:06:42 +00:00
ehouse
4ea3e72524 Make "Cur" string in tile-picker dialog localizable; move buttons in same for French to fit. 2007-04-24 13:34:21 +00:00
ehouse
019d701bf7 Call HsNavDrawFocusRing on Treo600, FrmNavDrawFocusRing on later
devices.  Fixes crasher on devices that don't have the former.  Up version.
2007-04-23 03:20:37 +00:00
ehouse
a0ec3417c2 add no-bt state so there can be no icon when bt's been left off; up
version and turn BT on by default for a8 release.
2007-04-16 05:22:49 +00:00
ehouse
9a86b69527 If BT is off, ask user to turn it on only once. If cancels, warn that
it must be turned on, and don't attempt to turn it on again.  This
prevents BTLib from repeatedly asking for permission to turn BT on.
2007-04-15 16:46:17 +00:00
ehouse
2f52acd5e6 cleanup (no change to generated code): remove old owner_hash code; replace empty formal lists with void. 2007-04-14 16:27:19 +00:00
ehouse
54e0ab64d1 Fix to compile with XWFEATURE_FIVEWAY undefined 2007-04-12 01:19:56 +00:00
ehouse
4f15c634d3 Turn off BT, and up version for first RC release. 2007-04-05 04:19:44 +00:00
ehouse
b965654db3 Closing BT lib from datahandler (since don't want to close on game
close in case next game will use); erase BT status icon when not BT
game; plug leak of dict name.
2007-03-18 23:57:30 +00:00
ehouse
6dc75914a6 turn stringFromStream into macro to aid logging for leak detection. Debug builds only effected. 2007-03-18 23:31:51 +00:00
ehouse
7997258163 Pad prefs struct so ARM and 68K versions are using same addresses
(fixes crash opening game in ARM version that was saved in 68K);
renumber resource IDs so can be logged via a switch.
2007-03-17 15:37:15 +00:00
ehouse
033df9c5af Save and restore focus owner across app restarts (includes working around
OS's insistence on sending focusTake event on formOpen); up version numbers; turn off BT prior to beta release.
2007-02-24 03:35:51 +00:00
ehouse
2b35dd68c7 Cleanup for a5 release: always use status icons when building for bluetooth. 2007-02-18 03:33:17 +00:00
ehouse
dc204c9aba code to use bitmaps instead of letters to show bt conn status. 2007-02-12 08:05:35 +00:00
ehouse
2d696b1e6c Fix nav for tungsten: test for lack rather than presence of keyUp events. 2007-02-08 15:16:46 +00:00
ehouse
51f726ddcf Add a one-byte header to BT messages so one device can signal another
that a new game's begun without dropping the connection.  On Palm,
remove connection-drop on new game.  With this change starting a new
game takes imperciptible time, down from 30 seconds.
2007-02-08 02:53:10 +00:00