ehouse
e0010901f1
add board_handleKeyRepeat, and call it from palm and gtk. This lets a
...
held nav key walk the cursor across the board.
2007-01-07 04:32:29 +00:00
ehouse
593980817f
Clean up for non-keyboard and non-keyboard-nav cases. Wince is the
...
latter: make it compile again.
2007-01-07 01:01:20 +00:00
ehouse
098a2ec5c4
Use new keydown/up APIs from linux, and add key support and drawing
...
changes to implement keyboard navigation/focus in gtk port.
2007-01-06 17:46:02 +00:00
ehouse
afc302a29b
When alt key pressed cursor can move onto occupied squares it normally skips.
2006-11-22 13:49:14 +00:00
ehouse
7fe5718cc5
When "dived" focus reaches and crosses border of object, return as if
...
not handled. This causes the platform to handle the key event itself,
typically by moving the focus to the next top-level object.
2006-11-17 13:41:13 +00:00
ehouse
cac0fd94d7
Use new top-level focus drawing model, and new API indicating whether
...
key handled.
2006-11-14 06:47:50 +00:00
ehouse
4ccddbd93f
add a done button
2006-11-13 02:02:15 +00:00
ehouse
84321fa158
fix drawing of empty tray space.
2006-11-12 15:39:10 +00:00
ehouse
eb32609a1d
Fix to compile and work with draw API changes
2006-11-12 14:51:47 +00:00
ehouse
2945a120f9
resend_all when a socket connects. This is the strategy needed with
...
Palm where apps quit and reopen connections many times during a game.
2006-11-11 22:44:31 +00:00
ehouse
9f0db2d9c5
add -lmcheck, which purports to catch memory errors
2006-11-11 22:42:40 +00:00
ehouse
b171900dfb
When moving focus through tray, skip empty space; when through board,
...
skip cells with tiles permanently played. Space char raises focus but does
not move it laterally.
2006-11-09 06:05:40 +00:00
ehouse
e8b74e1cc3
set focus to board if not held prior to passing keys
2006-11-08 05:05:11 +00:00
ehouse
2aa9664884
When internal focus reaches edge of object, move it back up and onto
...
the next object using a callback to the platform to determine what, if
any, object is next. Adjust curses platform to cooperate. Works
well. Palm is next.
2006-11-07 05:46:44 +00:00
ehouse
44eaa36319
More progress on one-handed navigation: fix ncurses board clipped to
...
bottom of tray; add focus-related params to draw*Finished routines
(and simplify to one) so platforms don't have to save from Begin
routines (and stop palm doing that); check version of saved game, and
handle case where older binary tries to open newer version; redraw
Palm tray buttons after focus change to stop focus-rect ghosting; fix
annoying overlap in saved games dialog; palm version goes to a3.
2006-11-05 16:54:18 +00:00
ehouse
3153e2b867
Lots of progress on one-handed navigation: add gadgets to stand in for board
...
scoreboard and tray on palm; make center drill into the focussed object and
spacebar come back up then move the focus among them. Integrate with other
focussable objects on main form. Go from separate drawCursor routines to
same for all three, with cursor only visible when focus is drilled down.
On curses, add a hilite rect routine that can be called after text is laid
down, and use for cursors.
2006-11-03 06:23:54 +00:00
ehouse
a735cfab03
use new XP_TriEnable type
2006-10-28 14:49:49 +00:00
ehouse
5f25ba9f57
remove BEYOND_IR, replacing with XWFEATURE_RELAY and
...
XWFEATURE_BLUETOOTH. The goal is to be able to build to support
bluetooth only, or relay/ip only, e.g. for a palm bluetooth beta.
Seems to work.
2006-10-10 01:34:37 +00:00
ehouse
d6ef943a5f
add linux_dict_getShortName
2006-09-24 15:35:33 +00:00
ehouse
6bae3385f4
fix compile warnings; disable board size combo when not new game.
2006-09-24 15:34:46 +00:00
ehouse
d46723eb6a
use gtk_combo_box instead of whatever and fix inability to set current
...
num players and role as dialog comes up.
2006-09-21 01:34:29 +00:00
ehouse
9137eff9fa
Largely untested changes to allow BT in ncurses mode, centered around
...
integrating sockets into poll fdset; move relay and bt globals out of
a union so can test if in use without knowing current connection method.
2006-09-19 03:39:08 +00:00
ehouse
7b7b7006a7
clean scoreboard rects before drawing in case player's location has changed as new players added
2006-09-19 03:35:26 +00:00
ehouse
ed1a7e6fc9
be a better master: don't try to send when not connected.
2006-09-16 15:21:27 +00:00
ehouse
40563a6790
strutils macro change; log PID on startup for easier attaching
2006-09-15 07:45:40 +00:00
ehouse
4479cf530d
Get rid of separate accept thread, instead integrating listening
...
socket into main event loop (poll underneath). Works for gtk; still
debugging ncurses.
2006-09-10 19:01:06 +00:00
ehouse
c27abcd486
Attempt to listen for connections on a separate thread so connected
...
game could disconnect and reconnect, but still need work on adding a
socket to the main thread's io queue from a different thread.
2006-09-08 07:23:19 +00:00
ehouse
f3eb95b891
Make linux client work as host. Currently accepts only one connection
...
and blocks in accept. Need threads and a piconet.
2006-08-29 13:20:09 +00:00
ehouse
fb87fd31d2
Start adding bt support to linux port. Required removing assumptions
...
that all connectivity was with relay and over streaming sockets (since
BT is using l2cap's datagram-style sockets.) With this checkin, a full
robot-vs-robot game is possible with palm as host and linux as client.
Linux as host isn't started yet.
2006-08-26 21:15:20 +00:00
ehouse
4daabf6fe5
Set -Wunused-parameter for those versions of gcc that support it, and
...
deal with the output by removing params where possible and elsewhere
by adding XP_UNUSED macro wrapping __attribute__((unused)). There
should be NO change in function in spite of the large number of files.
2006-08-16 13:44:44 +00:00
ehouse
0fed666438
script for averaging results of running 'time' multiple times.
2006-08-12 02:01:57 +00:00
ehouse
72bd18316d
juggle until something changes. This is better than there sometimes being
...
no change, until I figure out how to force drawing as on Palm.
2006-07-01 14:14:48 +00:00
ehouse
968dcf2835
removed a param from board_handlePenUp
2006-06-27 06:31:36 +00:00
ehouse
45979f547a
disable juggle button if only one player active; copy all four players when saving game state after dismissal.
2006-06-18 19:02:47 +00:00
ehouse
a4ac6f9ff4
call server_do after gameinfo dialog returns in case a player has
...
become a robot.
2006-06-14 06:22:21 +00:00
ehouse
b80808bc57
Support new tri-part enabled type; add "game info" dialog/menu to test
...
read-only side; support new attributes for column head and nplayers
label; hide labels as well as controls that go with them.
2006-06-10 05:50:27 +00:00
ehouse
956c169d08
Refer to players as "remote" rather than "not local" to be consistent
...
with Palm and PPC; fix juggle bug by adjusting lines after moving them.
2006-06-08 01:26:18 +00:00
ehouse
e58d397c2b
change newgame api names; implement juggle; change getter to take a
...
callback to copy strings that will go out of scope before the getter
returns (e.g. wince). Use changed API in gtk dialog.
2006-06-07 01:45:03 +00:00
ehouse
8c176ed53c
use common/nwgamest.c. Lots of code removed, and the dialog works now.
2006-06-07 01:28:37 +00:00
ehouse
90dfc15ae9
use signed types to avoid overflow and disappearing scores
2006-05-28 16:02:16 +00:00
ehouse
d0c6e8517b
center letter in tile even when it's too big.
2006-05-28 15:04:57 +00:00
ehouse
19414ae505
Finish scrollbar work by passing number of visible rows to
...
util_trayHiddenChange, which means an API change. In board, calculate
bottom of board based on bottom of tray when tray is hidden, and round
so that it's an exact multiple of cell height. In wince, take
advantage of the new parameter to fix the scrollbar so that very
constrained boards can be scrolled even when the tray is hidden.
2006-05-19 13:44:05 +00:00
ehouse
912d221b1c
Replace overlap param with nHidden to give more flexibility in
...
creating situations where board must be scrolled.
2006-05-17 06:10:24 +00:00
ehouse
e98ef5b962
move scrollbar into its own box so it doesn't force buttons to be over-tall
2006-05-14 15:26:21 +00:00
ehouse
94b46bc6c6
Incorporate svnversion output in usage()
2006-05-14 14:47:32 +00:00
ehouse
3ea23396d2
add compile-command
2006-05-12 07:59:38 +00:00
ehouse
ba1aefcd49
make tray hide button toggle hidden state
2006-05-12 07:59:21 +00:00
ehouse
543df9f681
minor code improvement
2006-05-11 03:02:11 +00:00
ehouse
7297ab4be8
fix layout for vertical scoreboard option
2006-05-09 12:31:41 +00:00
ehouse
3a4c5dfff6
catch up with API change
2006-05-09 04:04:56 +00:00
ehouse
aa09dfba91
catch up with API changes
2006-05-05 12:49:02 +00:00
ehouse
4ec6af22cb
Include name of dict so it can get printed.
2006-04-30 13:58:24 +00:00
ehouse
ef6ebe6bac
Add, and use, stream_putString. Saves 500 bytes on win32.
2006-04-25 13:31:15 +00:00
ehouse
63a8e0adbb
Add macros to draw.h, and use 'em for wince, so that a platform can choose to call draw.h methods via a vtable or static linking.
2006-04-01 21:01:20 +00:00
ehouse
10d38faa33
add install target
2006-02-27 00:08:32 +00:00
ehouse
e12abddcd9
new directories to ignore
2006-02-18 14:08:04 +00:00
ehouse
fb0d471dae
add const decls to draw.h and dictnry.h functions where appropriate,
...
and modify "subclass" methods to match. Should be no code change, but
this makes the intent of the APIs clearer.
2006-02-18 06:39:40 +00:00
ehouse
a4c7d48eb5
make XP_UCHAR signed to avoid warnings calling string.h funcs
2006-02-18 06:36:39 +00:00
ehouse
447af498a2
fix warning
2006-02-18 06:35:48 +00:00
ehouse
268442b782
use __VA_ARGS__ in debug macros
2006-02-17 07:29:25 +00:00
ehouse
a8add11453
clean up usage
2006-02-17 07:28:41 +00:00
ehouse
de830f328f
don't include in curses-only build
2006-02-17 07:28:17 +00:00
ehouse
e9499cb4ed
formatting only
2006-02-17 07:27:58 +00:00
ehouse
5aeb5dc6fa
makefile cleanup
2006-02-17 07:27:36 +00:00
ehouse
92485783af
update email address in header comments: no code change
2006-01-08 01:25:02 +00:00
ehouse
95005e45eb
don't connect to relay unless have something to send
2005-10-30 16:28:52 +00:00
ehouse
d29937a734
add a const
2005-10-30 05:06:41 +00:00
ehouse
a422f21ad5
add error message; cast to avoid compile warnings
2005-10-30 05:06:23 +00:00
ehouse
880b626070
add a few consts
2005-10-30 05:05:45 +00:00
ehouse
5e693ee022
fix misspelling; tweak error messages
2005-10-19 03:21:19 +00:00
ehouse
8c8babc762
new error message
2005-10-14 08:25:51 +00:00
ehouse
50df4d7cf4
catch up with API change
2005-10-01 15:53:56 +00:00
ehouse
237deee542
just log some messages so user interaction not required.
2005-09-14 05:11:29 +00:00
ehouse
5dace1cc7a
add enough timer support for heartbeat; fix redraw bug
2005-09-09 03:14:11 +00:00
ehouse
18fc5e2c14
add linuxFireTimer
2005-09-09 03:12:58 +00:00
ehouse
264f34d97d
move fireTimer to linux-common code
2005-09-09 03:12:24 +00:00
ehouse
368d2b82d6
add an extra slot as on other platforms
2005-09-09 03:06:27 +00:00
ehouse
763cd70632
add missing header. (Did gtk change?)
2005-09-09 02:57:14 +00:00
ehouse
5e4fd3368e
add role to newgame dialog
2005-09-05 05:31:11 +00:00
ehouse
aa0a9ec158
add error message; don't assert (crash) when socket closes.
2005-09-04 20:31:34 +00:00
ehouse
1aed9882ef
new (commented-out) info message
2005-09-03 18:36:08 +00:00
ehouse
ca8877a5de
for testing, add -H option to prevent client from sending heartbeat
...
messages to relay.
2005-09-03 15:39:15 +00:00
ehouse
1114784217
Add strings for error codes for relay disconnect events.
2005-09-03 06:58:05 +00:00
ehouse
e3cadfbf79
catch up with API changes
2005-09-02 06:24:47 +00:00
ehouse
c0bdfb54c9
constant name changed
2005-08-21 14:18:56 +00:00
ehouse
bc3515272c
Get rid of unused param
2005-07-14 02:54:47 +00:00
ehouse
3b53363e16
Pass protocol version code with connect request, and return error if
...
it isn't what relay can handle. Report error to user.
2005-07-06 01:36:52 +00:00
ehouse
c3f5fb4639
cancel old timer before setting a new one
2005-07-05 20:59:42 +00:00
ehouse
2871778cb7
remove logging
2005-06-25 05:44:30 +00:00
ehouse
767de5a284
implement new util_setTimer, and handle heartbeat timer
2005-06-23 04:20:00 +00:00
ehouse
cfa1a42fcd
fix formatting; make board wide enough for timer.
2005-05-30 00:20:42 +00:00
ehouse
40634e33c6
add justification to draw_string_at to better position using pango.
2005-05-30 00:03:58 +00:00
ehouse
8c201ff01b
give tiles a background color
2005-05-29 21:17:23 +00:00
ehouse
a83f1b46b6
Switch to GTK 2.n.
2005-05-29 20:40:38 +00:00
ehouse
3c23117a2a
New fields in drawCtxt for pango-based text layout; other tweaks for
...
switch to GTK 2.n.
2005-05-29 20:39:01 +00:00
ehouse
7986e14d08
huge set of changes to get working with GTK 2.n. Type changes and
...
casts, rewrite of img-button creation, tweaks in startup ordering that
may not have been necessary.
2005-05-29 20:37:35 +00:00
ehouse
521de82234
huge set of changes to get working with GTK 2.n. Use pango for text
...
drawing, getting rid of all GdkFonts; get rid of clipping until I
understand why it was prevent all drawing. Etc.
2005-05-29 20:32:48 +00:00
ehouse
2a39b6950f
switch to g_signal_connect
2005-05-29 20:17:09 +00:00
ehouse
ae8a861098
formatting fixes; casts for GTK
2005-05-29 19:37:42 +00:00
ehouse
961ca6e256
add linux_util_addrChange (stubbed out)
2005-04-03 16:56:39 +00:00
ehouse
bf331a2805
fix for api change
2005-04-03 02:47:08 +00:00
ehouse
b64103ad7e
don't use null comms
2005-03-25 13:41:18 +00:00
ehouse
b3432d4dfa
check for null comms before using
2005-03-25 03:13:10 +00:00
ehouse
1f3d94998f
define XP_LD
2005-03-20 21:03:18 +00:00
ehouse
7d622f9484
fix and cleanup linux client to move to using tcp. Add the ability to
...
deal with socket dying and (maybe) being replaced. Only connect on
demand now, when first packet's ready to go.
2005-03-19 22:07:53 +00:00
ehouse
02bc9178db
add XP_STRNCPY
2005-03-19 22:06:23 +00:00
ehouse
13b55cfeab
use compiler flags that ease debugging
2005-03-15 06:22:48 +00:00
ehouse
912f53178b
move playerNum into dsi so can be used in formatting score; show
...
most recent turn (like symbian 80)
2005-03-15 03:29:37 +00:00
ehouse
36bba4024b
move playerNum into dsi so can be used in formatting score
2005-03-15 03:27:24 +00:00
ehouse
af1416ed99
api change
2005-03-12 05:33:40 +00:00
ehouse
1c7e530538
deal with tcp streams the same in curses as on gtk. Both work now
...
with the relay.
2005-03-12 05:33:30 +00:00
ehouse
ef828a0bdf
fix misspelling
2005-03-09 15:12:57 +00:00
ehouse
897caf4e88
Replace UDP-based messaging with TCP. Stream protocol says distinct
...
message is length plus data. Use non-deprecated gtk select-like
function. With these changes can play full games through the relay on
gtk. Untested on ncurses but probably broken.
2005-03-06 18:07:00 +00:00
ehouse
572484ad53
API change
2005-01-25 04:41:47 +00:00
ehouse
f5a5d3d7a6
util function sig change
2005-01-13 04:30:50 +00:00
ehouse
6a569d5632
add missing param
2004-12-11 04:17:07 +00:00
ehouse
28b98cfd79
add HintAtts param to draw_drawBoardArrow
2004-11-14 16:27:51 +00:00
ehouse
4971a622ce
Make linux compile with latest changes
2004-11-09 02:06:32 +00:00
ehouse
00cc411f39
fix linux build: set up super's vtable
2004-10-30 17:01:20 +00:00
ehouse
b7f847194e
fix help message
2004-09-30 01:49:46 +00:00
ehouse
39f563cffb
turn on new features by default
2004-06-27 05:03:48 +00:00
ehouse
00c1f802fc
cleanup; use new API for limiting tile use from tray.
2004-06-27 05:01:18 +00:00
ehouse
d9efe4258b
cleanup for no hintlimit feature case
2004-06-27 04:35:42 +00:00
ehouse
2d63cdeda0
cleanup for no hintlimit feature case; add new param
2004-06-27 04:35:20 +00:00
ehouse
1568a27e3f
hint-rect on by default (until UI or cli option added)
2004-06-18 13:52:49 +00:00
ehouse
7efcdc80fe
draw borders on cells that are part of hint-constraint rect
2004-06-15 01:44:39 +00:00
ehouse
8164f918f7
only call board_handlePenMove when mouse button is down.
2004-06-15 01:41:39 +00:00
ehouse
61a05c3387
formatting fixes; add string for attempt to undo tile assignment.
2004-05-14 09:05:45 +00:00
ehouse
deaf860c5b
catch up with score-summary changes
2004-05-12 05:46:08 +00:00
ehouse
e85dc01638
new string as part of displaying last turn when score tapped
2004-04-30 08:38:46 +00:00
ehouse
d71e6a5a75
add XP_STRCAT
2004-04-30 08:37:30 +00:00
ehouse
bd5da24595
fix formatting
2004-02-28 05:23:10 +00:00
ehouse
0244afcde6
make util_userQuery return bool
2004-02-17 04:00:12 +00:00
ehouse
f684ec9461
draw_boardBegin returns bool now
2004-02-17 03:58:40 +00:00
ehouse
b447decb78
fix formatting
2004-02-17 03:56:12 +00:00
ehouse
34547f7fb7
drawBegin sig change
2004-02-13 13:54:52 +00:00
ehouse
05f2ae79b7
tweak dict-building sanity check
2004-01-25 14:31:34 +00:00
ehouse
d1df5342e4
set new dict variable
2003-12-14 17:55:45 +00:00
ehouse
5a915fe5d1
new file; -D option to workaround extra event leftover from probably
...
bug in new nTiles select dialog.
2003-11-30 19:10:47 +00:00
ehouse
589d9d3eaf
new slot
2003-11-30 19:09:39 +00:00
ehouse
03baf8cb2b
add test of board_requestHint change: limit number of tiles used in
...
hint.
2003-11-30 19:08:55 +00:00
ehouse
31017a455b
folloe board_requestHint signature change
2003-11-30 19:07:01 +00:00
ehouse
183eb9e283
first checked in
2003-11-30 19:06:22 +00:00
ehouse
8f1cfaec23
first checked in
2003-11-16 17:30:19 +00:00
ehouse
38f211270e
new menuitems (not yet used); blank-pick API change
2003-11-16 17:28:54 +00:00
ehouse
e9f34e8484
common code does more picking work now.
2003-11-16 17:25:46 +00:00
ehouse
4d31200290
util_userPickTile replaces util_askBlankFace
2003-11-16 17:17:04 +00:00
ehouse
f2766ec8e9
first checked in
2003-11-16 17:15:41 +00:00
ehouse
b5f54608da
remove code to new shared file
2003-11-16 17:14:28 +00:00
ehouse
9e966e7815
new files; commented-out -D option to turn on tile picking
2003-11-16 17:14:01 +00:00
ehouse
9bc9550a07
gettimeofday call burried in an assert; need to work for non-debug
...
builds too.
2003-11-01 05:56:24 +00:00
ehouse
5776da0b93
first checkin
2003-11-01 05:35:29 +00:00