Eric House
991cc8f04c
fail in main mode if udp socket not set
2013-01-20 21:03:43 -08:00
Eric House
e79b0bd3eb
Merge branch 'gtk_multigame' of ssh://xwords.git.sourceforge.net/gitroot/xwords/xwords into gtk_multigame
2013-01-20 19:27:50 -08:00
Eric House
21570ec9b4
Merge remote-tracking branch 'origin/android_branch' into gtk_multigame
2013-01-20 19:27:25 -08:00
Eric House
3df0484e6a
get maintenance mode message into an alert -- and create a new common
...
superclass for Service subclasses to reuse some code.
2013-01-20 16:07:38 -08:00
Eric House
fd2f4309f4
beginning of android changes to talk udp to the relay: sufficient to
...
get back (and log, not display) a message when the relay is in
maintenance mode.
2013-01-20 15:29:51 -08:00
Eric House
93ff4f4fcb
handle the new length-plus-string format
2013-01-20 13:07:01 -08:00
Eric House
016b16a8b2
change relay alert message format to length-plus-string rather than
...
null-terminated for easier handling on the java end.
2013-01-20 13:06:34 -08:00
Eric House
3fc31a6fe1
new enum for alert
2013-01-20 10:04:24 -08:00
Eric House
9023440a88
reply with alert to any connection attempt when in maint mode
2013-01-20 10:03:20 -08:00
Eric House
f06d129c24
change env variable name; provided inital board size and dict choices
2013-01-20 09:53:26 -08:00
Eric House
b768d8fccc
fall through to using hard-coded maxsocks value
2013-01-20 09:22:35 -08:00
Eric House
3dfb2e04e6
call comms_close in curses too to avoid new assert
2013-01-19 22:53:25 -08:00
Eric House
3313c776ab
fix unregister sql error
2013-01-19 22:37:12 -08:00
Eric House
3bcf5d504b
add a debug pref for turning on UDP-based networking (ignored so far)
2013-01-19 16:03:29 -08:00
Eric House
360602b3a0
fix compile failure: never meant to check this change in.
2013-01-19 16:02:58 -08:00
Eric House
6797e069bc
Merge branch 'android_branch' into gtk_multigame
2013-01-19 15:56:16 -08:00
Eric House
54ad381749
Merge remote-tracking branch 'origin/android_branch' into android_branch
2013-01-19 15:54:40 -08:00
Eric House
0ef3549a4e
handle (display) the relay's new error message
2013-01-19 15:18:36 -08:00
Eric House
65e9789c3f
add mainentance mode, triggered by a commandline flag, that does
...
nothing but loop waiting for connections on the UDP socket and sending
them back the error message provided on the commandline.
2013-01-19 15:17:51 -08:00
Eric House
1bb9f9b1bf
handle sending of messages generated by games opened only to receive
...
messages from relay. And handle report that relayID is bad.
2013-01-19 14:37:49 -08:00
Eric House
63d3f70cdf
more changes to storage and fetching of messages and to protocol so
...
presence of messages is reported on connect (as are bad relayIDs).
Now a game with a robot player in a "closed" game can continue. Once
the next set of linux-side chances is committed.
2013-01-19 14:34:04 -08:00
Eric House
99307e45a0
queue incoming packets and process them in order in a separate thread
2013-01-18 19:56:21 -08:00
Eric House
1519a00004
toward being able to handle messages received for closed game.
...
Receipt seems to work but send in that state doesn't.
2013-01-18 07:49:00 -08:00
Eric House
c999bbae92
always test those last-minute pre-checkin cleanups
2013-01-18 07:22:56 -08:00
Eric House
3984d85795
oops -- prev checkin didn't compile
2013-01-18 07:12:26 -08:00
Eric House
1c5fef6a38
relay improvements for UDP connection: record addresses, prepare to
...
run in separate thread, etc.
2013-01-18 07:10:47 -08:00
Eric House
932778f700
stubbed-out thread manager for udp connection
2013-01-18 06:57:57 -08:00
Eric House
4163309dae
Let's have just one set of signal handlers
2013-01-17 06:37:53 -08:00
Eric House
2f772c56b2
make gtk app a better test bed: add db and row to window titles,
...
implement delete button and multiple selections, etc.
2013-01-16 21:16:07 -08:00
Eric House
c33c50ee6b
add deleteGame()
2013-01-16 21:11:35 -08:00
Eric House
a6784464ff
first set of networking changes testing per-device communication with
...
relay on behalf of a number of games. Works as long as all the games
are open.
2013-01-16 06:46:33 -08:00
Eric House
f6e7ece578
add comms_stop() and an assert to make sure it's called. Explicit
...
stop and a message to the relay when using a UDP socket makes up for
there being no notification of connection closing.
2013-01-16 06:31:09 -08:00
Eric House
a107365c88
change names of two types and variables of that type to make a common
...
pattern more sensible. No code changes.
2013-01-15 19:04:20 -08:00
Eric House
7fec736947
add udp socket and protocol for use over it so that a device can
...
manage a single connection to the relay for all of its games. Works
so far to the extent that the game's playable with all boards on the
same device (with checkins about to come) as long as all boards are
open. (Client doesn't handle opening closed games yet.)
2013-01-15 18:41:17 -08:00
Eric House
5a51af489a
Merge branch 'android_branch' into gtk_multigame
2013-01-13 10:41:14 -08:00
Eric House
dc0cfdf001
bug in recent changes: need to mark socket unused to avoid double removal
2013-01-13 10:37:47 -08:00
Eric House
98679c8363
cleanup: better encapsulation for AddrInfo
2013-01-13 10:14:06 -08:00
Eric House
c567647a8d
get rid of mapping of socket->game_connection, which will not work
...
once UDP sockets and/or per-device (not per-game) connections come
along. Lots of changes, most not involving code flow but a couple
that did. So far two gtk games can connect and exchange moves.
Haven't tested reconnection or store-and-forward.
2013-01-12 16:09:24 -08:00
Eric House
33735ae7a5
Merge branch 'android_branch' into gtk_multigame
2013-01-11 20:48:44 -08:00
Eric House
b46df07237
Merge remote branch 'origin/android_branch' into android_branch
2013-01-11 20:48:04 -08:00
Eric House
6dcd7022d4
don't pass .css file in; it's ignored
2013-01-11 20:42:57 -08:00
Eric House
55514719be
include thread ptr in hung threads logging; assert (restart) when hung for too long
2013-01-11 20:42:04 -08:00
Eric House
39d12d088a
use usleep when waiting for cref to be available
2013-01-11 20:37:08 -08:00
Eric House
aed2b6135c
Merge branch 'android_branch' into gtk_multigame
2013-01-10 21:10:48 -08:00
Eric House
2ccc297463
make number of sockets at which we assert/reboot configurable so tests
...
can be done with large numbers of clients.
2013-01-10 21:10:18 -08:00
Eric House
dddb135b9d
add more columns, and update each time game is saved
2013-01-09 06:30:52 -08:00
Eric House
7437a71aa6
use string_printf
2013-01-09 06:29:12 -08:00
Eric House
fac3e6b678
fix gtk version to correctly implement util_setIsServer (which only
...
Android did so far) by calling server_initClientConnection(). Now
relay games work with both started as hosts. (GTK UI prevents
starting one as a guest; cmdline is required for that, if it still
works.)
2013-01-08 07:28:30 -08:00
Eric House
5e2bfd20da
add a checkbox -- which apparently won't interact until I "implement
...
the 'activate' virtual method".
2013-01-08 06:32:43 -08:00
Eric House
1cb959c86d
type tree model column correctly
2013-01-07 20:51:59 -08:00
Eric House
76f3bb3413
fix curses version so discon_ok2 tests work again.
2013-01-07 20:40:46 -08:00
Eric House
565b742971
snapshot -- connects to relay but doesn't play yet.
2013-01-07 08:00:47 -08:00
Eric House
469e656464
track open games so don't double-open and can close all on quit
2013-01-07 06:36:34 -08:00
Eric House
f88387da80
lots of changes to separate game data from app data so several games
...
can be open at once. (curses version is almost certainly broken)
2013-01-07 06:10:44 -08:00
Eric House
b61ed7b631
opening saved games and saving of changes now work.
2013-01-05 21:01:26 -08:00
Eric House
a8014a855b
now games are displayed in lists. Next: open them.
2013-01-05 19:40:29 -08:00
Eric House
8238d45350
ignore the db
2013-01-05 19:37:05 -08:00
Eric House
e0dc83ed70
rest of what I just meant to commit.
2013-01-05 16:08:47 -08:00
Eric House
4af30c534c
snapshot. New game button works and game gets saved in DB. Next: display and open from DB.
2013-01-05 16:08:19 -08:00
Eric House
63487dc5d0
assert gdk setup going ok
2013-01-03 08:18:35 -08:00
Eric House
f827bebf80
ignore .pyc file
2013-01-02 21:13:36 -08:00
Eric House
ad78129e74
changes made over the past couple of months toward tracking an
...
apparent thread leak.
2013-01-02 21:12:42 -08:00
Eric House
d34ac1f86d
rewrite to work without gcm library (whose lack of support for some
...
documented params makes it impossible to try using them)
2013-01-02 21:08:10 -08:00
Eric House
f5b8bb7aae
fix text to match there being multiple buttons
2013-01-01 23:26:31 -08:00
Eric House
2202c6c6bf
up version strings and number
2013-01-01 22:33:31 -08:00
Eric House
c97ec6b1e9
up copyright year -- it's 2013 now
2013-01-01 22:33:19 -08:00
Eric House
05cee5ce09
further work supporting simultaneous dialogs: use
...
bundle.get/putSerializable() to save/restore dialog state
2013-01-01 22:27:14 -08:00
Eric House
af406d92dc
Handle multiple dialogs at once: save dialog state by dialog ID (ok
...
since the OS won't track more than one at a time with the same ID) and
look it up that way when needed. Get rid of onPrepareDialog() (and in
all my Activity subclasses) since it's now a requirement that all
DlgDelegate-managed dialogs remove themselves from the Activity on
dismissal so that onCreateDialog will always get called and
onPrepareDialog not be needed.
2013-01-01 21:45:37 -08:00
Eric House
8b2712bd9e
always remove dialog on dismissal since each must have its on-dismiss
...
handler called with its own state. Fixes assertion failure that was
happening the second time a dialog was used. Next: find a
reproducible case where two dialogs want to be created at the same
time.
2012-12-31 07:08:41 -08:00
Eric House
d1941090c5
Merge branch 'android_branch' into fix_dlgdelegate
2012-12-31 06:25:49 -08:00
Eric House
049b3389a6
turn DEBUG back on
2012-12-29 18:49:13 -08:00
Eric House
bbf9e8e0df
tweaks suggested by code review
2012-12-29 13:22:00 -08:00
Eric House
1faf60f667
move updateRow back where it was (prior to some merge); no code change
2012-12-29 12:50:02 -08:00
Eric House
90adcde164
move side padding around
2012-12-29 12:42:48 -08:00
Eric House
04a7f9c999
tweak text; fix misspelling
2012-12-29 12:30:01 -08:00
Eric House
05566b1833
add space before ) to protect against buggy email url parsers.
2012-12-29 12:24:13 -08:00
Eric House
e58e520f70
fix name/rename group dialog title
2012-12-29 11:53:18 -08:00
Eric House
498ca99020
deal with added groups too, and better with removed groups.
2012-12-29 11:36:51 -08:00
Eric House
8c4b878e21
preserve order of groups when removing one by removing it from list
...
rather than allowing list to be regenerated.
2012-12-29 09:35:44 -08:00
Eric House
674b6d3e8e
don't let new group dialog present the last name chosen as default name
2012-12-29 09:18:17 -08:00
Eric House
78670e9650
fix bug: include wordlist name in bad word info passed into util function
2012-12-29 07:48:31 -08:00
Eric House
ad2b925a60
print wordlist name as part of error message
2012-12-29 07:47:44 -08:00
Eric House
ff3af7f095
add xml-non-strippable space between sentences
2012-12-29 07:47:12 -08:00
Eric House
c994b27c04
try grey background and italic text for list group views
2012-12-28 20:01:13 -08:00
Eric House
4d07046a99
make static GamesListItem method responsible for providing new instances.
2012-12-28 20:00:46 -08:00
Eric House
21e572acfc
Revert "use WeakReference to cache GameListItems and to inval them"
...
(Reusing Views this way seems to cause the occasional failure to recognize a tap-on-item bug.)
This reverts commit edd712ac16
.
2012-12-28 10:06:16 -08:00
Eric House
edd712ac16
use WeakReference to cache GameListItems and to inval them
2012-12-28 09:50:33 -08:00
Eric House
fb575949ac
order games within group the same way all games used to be ordered,
...
and get rid of the old all-games-listing code since it's no longer
used.
2012-12-27 20:50:37 -08:00
Eric House
a6586b6131
docs say not to call cursor.close -- so don't.
2012-12-27 20:38:31 -08:00
Eric House
8bba5d6106
Revert "add POSITION column to groups table, unused as yet"
...
This reverts commit 7be6a182f0
.
2012-12-26 19:35:21 -08:00
Eric House
68026fef3e
disable (but don't hide) group context menus that can't do anything.
2012-12-26 19:31:24 -08:00
Eric House
0d9f1a3ba7
add move-up and move-down menuitems so group order can be controlled
...
by user. Store position as array of rowids in preferences, and make
game info hashed by rowid rather than name.
2012-12-26 18:55:15 -08:00
Eric House
0a7fcb2de4
remove deleteAll menuitem
2012-12-22 23:21:01 -08:00
Eric House
7be6a182f0
add POSITION column to groups table, unused as yet
2012-12-22 22:59:08 -08:00
Eric House
3ce379588b
indent game list items to make them easier to tell from group items
2012-12-22 22:54:10 -08:00
Eric House
110df3c1ba
Merge branch 'android_branch' into fix_dlgdelegate
2012-12-21 23:03:22 -08:00
Eric House
a594a77673
Merge branch 'android_branch' into android_groups
2012-12-21 18:06:48 -08:00
Eric House
2461b526a5
move check for updates into async task
2012-12-21 18:06:27 -08:00
Eric House
e8c3c304ab
Fix so when child is invalidated its group/parent also is. Now when
...
an invisible child gets a network game message that changes its expiry
rendering and it's the one the group is showing, the group will follow.
2012-12-21 17:31:37 -08:00
Eric House
3436a71d65
new string for dialog title (forgot this last checkin)
2012-12-21 17:29:44 -08:00