Commit graph

4046 commits

Author SHA1 Message Date
Andy2
feca7345dc add GameFull -- database, not in-memory state, knows if game is full. 2010-11-15 06:48:36 -08:00
eehouse@eehouse.org
14579c6e30 Merge branch 'relay_proxy' of ssh://xwords.git.sourceforge.net/gitroot/xwords/xwords into relay_proxy 2010-11-14 19:40:35 -08:00
eehouse@eehouse.org
6ae288d800 Merge branch 'relay_proxy' of /home/andy2/dev/git/LOCAL_ORIGIN into relay_proxy 2010-11-14 19:35:31 -08:00
Eric House
528ae0c986 allow more than one device death per message 2010-11-14 15:19:38 -08:00
Eric House
a8ac30b180 add -d option to test dev-gone on relay 2010-11-14 15:18:49 -08:00
Andy2
9026d5c149 remove obsolete script I keep accidentally invoking 2010-11-12 18:26:01 -08:00
Andy2
43896ff187 remove unused method and variable 2010-11-12 18:25:15 -08:00
eehouse@eehouse.org
6663ce5655 Merge branch 'android_branch' into relay_proxy 2010-11-11 06:51:15 -08:00
Andy2
fc8cac3b6a handle new device-gone message by posting timed-out dialog. 2010-11-11 06:43:36 -08:00
Andy2
b0a4790ce0 respond to new game-gone message by passing to utils. 2010-11-11 06:41:24 -08:00
Andy2
0787a06eb5 accept new message from device announcing the death of a game
(including seed so it's harder to spoof); respond to that by setting a
DEAD column in the db and flagging the device as gone.  Notify any
connected device of the fact.  Refuse to accept new connections to
that game.  As already-connected devices reconnect, allow them to do
so but send a new status message that their game is dead.  Not heavily
tested yet.
2010-11-11 06:40:50 -08:00
Andy2
3d59bc7e39 add new DEAD column to track when a game's been deleted 2010-11-11 06:29:21 -08:00
Andy2
04e1b0c22b new constants, include new status event type, for relay to accept
notification of deleted game and communicate that to others in the
game as they connect.
2010-11-11 06:26:59 -08:00
Andy2
d809db7b21 plug into delete and reset code to notify relay that game's forever gone. 2010-11-11 06:25:08 -08:00
Andy2
cf84cce41a define and handle new other-was-deleted error relay is about to start
returning.
2010-11-11 06:23:48 -08:00
Andy2
e3f373039a add informOfDeath to communicate to relay when game is deleted 2010-11-11 06:22:38 -08:00
Andy2
4761169c2b switch to RelativeLayout, putting lock checkbox at top and play game
button in the middle with everything else scrolling in between.  This
particular application of RelativeLayout works on 1.5 (in emulator).
2010-11-11 05:46:23 -08:00
eehouse@eehouse.org
048eff92b8 Merge branch 'relay_proxy' of /home/andy2/dev/git/LOCAL_ORIGIN into relay_proxy 2010-11-10 07:17:39 -08:00
eehouse@eehouse.org
7929167129 Merge branch 'android_branch' into relay_proxy 2010-11-10 07:06:10 -08:00
Andy2
f373b52d45 fix bug drawing tile letters when drawScaled() got triggered (e.g. for
W on non-std-sized screen): pass null as scr rect to drawBitmap so the
whole bitmap gets used.
2010-11-10 07:05:40 -08:00
Andy2
d3e644db83 stop requiring 1.6 sdk when runs fine on 1.5 2010-11-10 06:57:45 -08:00
Andy2
c8d7ca40a5 use \1 instead of \n as delimiter -- in case somebody passes as string
containing a \n.
2010-11-09 18:02:22 -08:00
Andy2
0f111ab363 use PQexecParams instead of PQexec for queries involving strings from
users (i.e. room names) to avoid crashes when the contain apostrophes
-- and in general to be safer.
2010-11-09 17:27:33 -08:00
Eric House
966616cbc4 throw in the public flags; disallow unset variables 2010-11-09 05:54:23 -08:00
Eric House
2a2f4d4395 been a while since cvs... 2010-11-09 05:53:49 -08:00
Andy2
42481a31cc add seed to db; get and set it. 2010-11-08 17:23:54 -08:00
Andy2
82876bda06 add seed and fetch it in jni 2010-11-08 17:23:16 -08:00
Andy2
22f7a42c1d make comms_getChannelSeed non-static so jni can call it 2010-11-08 17:22:38 -08:00
Andy2
b49015c9a1 map out-of-range lang codes to 0. Otherwise we get outOfBounds
exceptions once Hex dict is installed.
2010-11-07 15:42:09 -08:00
Andy2
d893632e1b map out-of-range lang codes to 0. Otherwise we get outOfBounds
exceptions once Hex dict is installed.
2010-11-07 15:34:40 -08:00
Andy2
83ae8d316c switch to RelativeLayout, putting lock checkbox at top and play game
button in the middle with everything else scrolling in between.  This
particular application of RelativeLayout works on 1.5 (in emulator).
2010-11-07 15:13:39 -08:00
Andy2
aff3c9a931 stop requiring 1.6 sdk when runs fine on 1.5 2010-11-07 15:12:37 -08:00
Andy2
1e5ac393c1 update for b18 (but leave b17 description below since that represents
two months of work and b18 two hours.)
2010-11-07 14:13:04 -08:00
Andy2
6da013af9d up constants for beta-18 2010-11-07 14:04:37 -08:00
Andy2
c2472c0cb5 don't call java code if rect width is 0. Fixes crash (but not design
problem) where first to connect in room specifies a timer and second
does not.  Second eventually gets message saying there's a timer but
has not layed out space in the board and java freaks out when later
asked to make a 0-width image.  This fix leaves the device not drawing
the timer until the game is reopened.  The better fix would trigger a
re-layout as soon as the change is made.
2010-11-07 14:03:24 -08:00
Andy2
cfd4345287 remove too-frequent logging 2010-11-07 13:31:43 -08:00
Andy2
99a557a604 fix blanks-first option to assign one blank per tray rather than all
to first.  Makes for more realistic test.
2010-11-07 12:20:39 -08:00
Andy2
83f6ebca79 work around bug -- or design flaw -- where when timer is set hint or
robot with blank in tray keeps flashing the in-progress indicator by
flagging CMD_TIMER_FIRED as a non-ui event so busy() won't return when
it's what's on the queue.  Problem with that is that the timer stops
advancing during a hint which is clearly not what's happened.
2010-11-07 12:13:07 -08:00
Andy2
2c95179050 don't complain about empty room name for standalone game 2010-11-07 11:50:01 -08:00
Andy2
57838c0436 improve script. Allow pass either branch or tag on commandline,
defaulting to branch of tree from which called.  Add usage().  set -u
-e and deal with [ -n "$1" ] being an error in that case.
2010-11-07 08:16:36 -08:00
Andy2
46a01ace56 work around occasional crash in on-device testing by checking for 0
before passing to getString.  Not sure of the circumstances but the
crash is coming from restoreManagedDialogs() -- might be related to
screen orientation changes.
2010-11-06 21:34:16 -07:00
Andy2
dd3bd1f661 don't show hint buttons until there are tiles assigned 2010-11-06 21:31:53 -07:00
Andy2
a6a7f1899d remove logging 2010-11-06 21:01:50 -07:00
Andy2
2fc48cbd97 nuke unused constant 2010-11-06 21:01:29 -07:00
Andy2
92ec742f90 script to build from a clean tree. I'm getting emacs and git tmpfile
picked up by the android build system and incorporated into .apks;
this will avoid that.
2010-11-06 20:19:07 -07:00
Andy2
d2782af487 do case-insensitive comparison of room names 2010-11-06 18:52:10 -07:00
Andy2
73d7c7a27b use new field to determine if simple relay config dialog can handle
the game or if user's already changed it enough that the full-on
dialog is required.
2010-11-06 18:26:09 -07:00
Andy2
f36b253ae7 add number of players to GameSummary. Changes DB but it's already
changed since last beta so I'm not upping the version.
2010-11-06 18:24:44 -07:00
Andy2
9fccbcc6b4 Problem with new minimal-config relay dialog: user can accidentally
tap "play game" and wind up connecting and creating an empty-room-name
game; or can dismiss the dialog and be confused because there's no way
back to it.  Solution: define empty-room-name as an illegal case.
Check for it when "play game" is tapped in either config dialog and
raise an alert.  And when user wants to open a game from the GamesList
activity go to the minimal config dialog if it's a relay game without
a room name.
2010-11-06 16:41:12 -07:00
Andy2
8213c9a5c1 add showOKOnlyDialog 2010-11-06 16:38:33 -07:00