ehouse
90a10345b8
Fix trade window draw and timer draw by setting clip rect. Change
...
softkey to turnDone when trading. Tweak trade-related user messages.
2008-05-11 15:25:04 +00:00
ehouse
255592ddec
remove unnecessary memset
2008-05-11 13:55:58 +00:00
ehouse
8a6df572ae
add some consts.
2008-05-06 12:49:37 +00:00
ehouse
536de24e1d
Put game name in title bar on launch as well as after opening saved
...
game. Clear when opening unnamed/defaultnamed game
2008-04-13 17:01:09 +00:00
ehouse
f1ec47aa93
force miniwindow entirely onto board even if natural position is on
...
tray; fix overdrawing onto miniwindow by making timer proc return a
boolean and only redrawing (on wince) when it's true.
2008-04-12 15:36:31 +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
120592324a
remove excessive logging
2008-04-02 03:50:55 +00:00
ehouse
4518bbdc05
Force redraw after timer fires. This allows scrolling to happen
...
during drag, but isn't the right fix. The timerProc should probably
return a boolean indicating whether redraw is needed.
2008-03-31 00:25:18 +00:00
ehouse
63c0cd8aee
Use new APIs to scroll dialogs; use new saved games dialogs.
2008-03-24 12:41:12 +00:00
ehouse
c42e76af5b
Use MessageBox instead of my StrBox on Smarthphone; do away with
...
scrollbar on Smarthphone since there's no touchscreen and I want the
space. Still need to find a way to scroll screen.
2008-03-15 21:56:37 +00:00
ehouse
243c645c20
Change About box implementation from separate dialog to str resource
...
passed to MessageBox
2008-03-15 19:24:59 +00:00
ehouse
ef5e20d708
Don't subtract command bar height from client rect height on
...
smartphone. This prevents windows from being too small in
non-fullscreen mode. Make ceSizeIfFullscreen work based on state
rather than assuming it's toggling.
2008-03-15 18:32:22 +00:00
ehouse
c9101ec801
Rework dialogs to fit or (eventually) scroll on small screen; put
...
dialogs in fullscreen mode; switch from dropdowns to spinbuttons on
CE; grab OS version on startup (not yet used.)
2008-03-15 15:39:58 +00:00
ehouse
2c3b7b23db
Work on soft key and menu: derive text from menu item being moved so
...
that we can pull out and later replace any item by id alone. Do
something similar on Win32 to ease development. Remove '&' from
menuitem text, allowing winders to assign command keys, so that we
don't have to pull it before assigning text to softkey.
2008-03-10 01:47:46 +00:00
ehouse
78dfed6c59
Put back "turn done" menu, and add call to change the left softkey.
...
Call it when turn changes, new game is begun, and hint feature has
been used. Currently menuitem is duplicated. Goal is to remove the
item being attached to the left button and to replace it when another
is chosen.
2008-02-26 13:49:41 +00:00
ehouse
7da5ce74f4
Convert prefs in old format to new when encountered so that users
...
don't lose settings on upgrading.
2008-02-23 22:06:05 +00:00
ehouse
0b5a14c424
Add ENABLE_LOGGING define so logging can be used on non-debug builds, e.g. to trace opening of non-debug saved games and prefs files.
2008-02-17 21:48:48 +00:00
ehouse
25b568d22e
Fix timers to work even when message queue is full; make fullScreen
...
choice persistent; clean up resource file and add missing strings.
2008-02-16 17:36:46 +00:00
ehouse
642e6611db
Mark params unused in compiles for standalone; remove unused param.
2008-02-16 16:02:49 +00:00
ehouse
145e55c7f0
Add resource for two-soft-key commandbar and put it up. The single item is "Done" for now.
2008-02-05 04:57:58 +00:00
ehouse
2386ab6b31
Add full-screen mode and menu to get to it (leaving the cmdbar/softkey
...
area in place until I figure out how to work a UI without a visible
menu); rework menu to launch new-style from a single softkey; remove
cmdbuttons and associated resources; limited progress on handling
return key/timeouts for keyboard navigation.
2008-01-20 15:36:17 +00:00
ehouse
a9d1697c7b
Update to use modified newg_store
2008-01-05 16:37:49 +00:00
ehouse
e894a44b61
Fix compilation errors. Not tested.
2007-12-03 01:18:13 +00:00
ehouse
b527110379
replace all __FUNCTION__ with __func__
2007-12-02 19:13: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
6dc75914a6
turn stringFromStream into macro to aid logging for leak detection. Debug builds only effected.
2007-03-18 23:31:51 +00:00
ehouse
2fe75a19a2
add const to a bunch of char* decls in APIs and variables; no code change
2007-02-03 17:54:20 +00:00
ehouse
b4d01f15f2
preliminary addition of xplatform-only focus, esp drawing of cursor
...
and handling of arrow keys via WM_KEYUP; added focus/cursor color to
prefs and color edit dialog. Tested only on win32 (WINE), and not
integrated with platform nav/focus model.
2007-01-19 08:24:02 +00:00
ehouse
3a0b5af472
change constant names. No change to code compiled.
2007-01-19 06:43:52 +00:00
ehouse
40832e6ea5
reintroduce board_handleKey
2007-01-18 02:42:37 +00:00
ehouse
4646ac5711
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
e5e36f0fa4
Use new XP_TriEnable type; begin work to support bluetooth by tracking
...
connType and adding choice how to connect. Bt connect dialog is
invoked, but the fields won't be populated. Pass conn type into
socket constructor, assuming socket code doesn't change much to use BT
rather than TCP.
2006-10-28 14:56:04 +00:00
ehouse
912fe93829
add a few consts decls where APIs changed; use XWFEATURE_RELAY rather
...
than BEYOND_IR
2006-10-22 19:44:30 +00:00
ehouse
ba4f91d9e0
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
5780da7b93
catch up with recent API changes; fix bug in newgame dialog.
2006-09-15 07:39:57 +00:00
ehouse
f561989644
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
cfb5e57d07
fix broken ce build: remove ifdefs.
2006-08-11 01:33:19 +00:00
ehouse
d35f5100ab
Compensate for OS' failure to deliver penup events by checking for
...
pendownness at critical points when an up event should have been
processed: when another pen down happens, when about to scroll, and
when events (menus and buttons) occur. This seems to catch all the
lingering miniwindow problems. Add flip menuitem (win32 only for now).
2006-07-07 08:39:31 +00:00
ehouse
78dd247307
add more cases to messageToBuf. Effects debug build only.
2006-07-03 22:32:29 +00:00
ehouse
00e4c06857
add messageToBuf (debug-only ); change newgame's J button to R (for
...
"rearrange"); tweak locations of various dialog widgets for better
layout.
2006-07-02 00:42:41 +00:00
ehouse
a272ab15ef
Get rid of param removed from board_handlePenUp.
2006-07-01 14:22:09 +00:00
ehouse
ea5ba414cd
remove overactive log message
2006-06-22 03:37:21 +00:00
ehouse
29621ec4d1
Run server after gameinfo dialog dismissed in case a player's become a robot.
2006-06-15 12:39:54 +00:00
ehouse
c956b0858a
cleanup; fix compile of non-debug win32 version
2006-06-11 20:12:20 +00:00
ehouse
9d18e8df95
Add "Save current game as" to save file dialog; remove frequent-save hack.
2006-06-11 05:27:16 +00:00
ehouse
f7ee793df3
Catch up with changes including three enabled states for control and
...
setting dialog strings. Align titles with columns for standalone version.
2006-06-10 16:15:31 +00:00
ehouse
12daa9bfbb
Turned on leak-checking at shutdown for debug version, and fixed leaks and
...
crashes in destructors that had never been called before. Seems now to
free all allocated memory before exiting.
2006-05-30 05:12:02 +00:00
ehouse
35f8004d43
fix a couple of compile warnings
2006-05-28 14:53:02 +00:00
ehouse
c2ddb62591
modify API for "portraitizing" dialogs, and space the buttons evenly
...
rather than stacking all from bottom. This doesn't quit work on ce
since GetWindowInfo isn't available and IsWindowVisible does the wrong
thing.
2006-05-27 17:18:42 +00:00
ehouse
3ca36f57fc
For dialogs in portrait-mode, move OK and Cancel buttons to the right
...
side and shrink up from the bottom
2006-05-25 03:41:32 +00:00
ehouse
54468b01bb
update nHiddenRows so scrolling finally works
2006-05-20 06:22:33 +00:00
ehouse
e8273bc9f0
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
4c1f0f7454
factor out updateScrollInfo so I can update scroller live once I get
...
super-small boards figured out.
2006-05-14 15:28:57 +00:00
ehouse
bdc2300f84
Add ability, in win32 version, to specify height and width on wine's
...
commandline -- to ease debugging of layout code.
2006-05-12 07:54:59 +00:00
ehouse
7d9d97cd88
Turn on -Wall for compilers, and fix warnings that result. Got 'em
...
all for win32 build, but some remain for wince that I'm unable to fix.
2006-05-12 07:17:35 +00:00
ehouse
c9606b6d0b
fix too-tall cells in vertical scoreboard case
2006-05-11 03:01:39 +00:00
ehouse
58f4b08623
first cut at supporting landscape mode by moving scoreboard to left edge of screen from top.
2006-05-09 02:01:27 +00:00
ehouse
f4844efd2f
Alert user of a previous version that dict location is being fixed
2006-05-05 12:51:08 +00:00
ehouse
4e2b080be5
Add, and use, stream_putString. Saves 500 bytes on win32.
2006-04-25 13:31:15 +00:00
ehouse
1c4f0a47b7
When unable to open a dictionary whose path has been saved, look for
...
it elsewhere in the set of possible directories. This should help
ease the transition to there being a limited number of places where
dicts can be, since games saved previously will still work after the
dicts they reference have been moved. Also, clean up callbacks making
their return values consistent: true means done.
2006-04-25 04:25:08 +00:00
ehouse
9acbe29bf5
Replace generic "no dictionaries found" warning with list of directories searched and URL from which to download.
2006-04-24 04:34:42 +00:00
ehouse
e8a18f10de
rewrite ceLocateNDicts to do recursive searches from a list of
...
directories stored in resources. On device this is currently
"\Program Files\Crosswords" and "\SD Card". (Just "." for win32.)
Later may need to restrict on the card too. Still to do: make "no
dicts found" Alert list the places searched.
2006-04-22 14:05:09 +00:00
ehouse
4e483b03a5
forgot to save before commiting....
2006-04-19 04:57:51 +00:00
ehouse
25b1fb4ecf
ceLocateNDicts now takes a callback. Use that to build menu of dicts
...
rather than call OpenFile, which doesn't let you browse much of the
file system on CE. Heading for installing dicts in Program Files so
users never have to worry about them.
2006-04-19 04:56:00 +00:00
ehouse
76c6a56f93
Rewrite dictionary location code so that it can more effeciently
...
produce a list of dictionaries. The API has changed slightly, but the
new ability isn't used yet.
2006-04-16 05:12:52 +00:00
ehouse
ea812d81ea
Fix crash when no dictionary by checking for null model before calling
...
cePositionBoard on WM_SETTINGCHANGE event
2006-04-02 21:52:15 +00:00
ehouse
7bace099ed
tweak code so board is right width in release build. Looks as if I'm
...
working around a code-gen bug, but I haven't looked at the asm output.
2006-02-19 05:48:51 +00:00
ehouse
04ead8566c
tie aygshell to Wince rather than making it separate feature
2006-02-17 07:30:54 +00:00
ehouse
35b7a7900f
get rid of printf
2006-02-16 03:32:19 +00:00
ehouse
49801fb0ee
provide sensible path for saved files on win32 so state can be preserved
2006-02-15 13:09:36 +00:00
ehouse
c767c89d64
back out change that had window drawing too narrow
2006-02-07 14:45:30 +00:00
ehouse
bc6cfacedb
cleanup closing in on building correctly -- which now works, though it
...
takes a hex editor. May have fixed a bug with a missing CloseHandle
call.
2006-02-06 04:41:14 +00:00
ehouse
3ef2bf9c8e
pass the right param to WinMain. This makes it work on ce!
2006-01-31 06:41:16 +00:00
ehouse
3174ff031f
use debhacks; ifdef out cmdbar stuff which debian tools don't support yet
2006-01-28 19:02:04 +00:00
ehouse
dcd31cd092
update email address in header comments: no code change
2006-01-08 01:25:02 +00:00
ehouse
21c28dfcd9
add random seed in win32 case
2005-11-27 23:11:05 +00:00
ehouse
c4643ee5b4
Increase size of tray and fonts for win32; turn on windoze-style
...
menus.
2005-11-27 22:06:04 +00:00
ehouse
4d2ed4f0f6
changes for gcc compilation: fix syntax errors and API usage,
...
conditionally define out stuff that doesn't work on win32
(e.g. CommandBar).
2005-11-27 20:16:43 +00:00
ehouse
4ff2f68bd7
add strings for relay errors
2005-09-07 12:31:32 +00:00
ehouse
bd121ed939
protect logging with mutex since happens from multiple threads now.
2005-08-21 14:54:49 +00:00
ehouse
05e9bd2d12
flesh out interaction with comms. Now able to play a complete game vs
...
linux version over GPRS.
2005-08-21 14:36:11 +00:00
ehouse
cca35b28db
tweak how timers stored
2005-08-21 14:07:29 +00:00
ehouse
3b79617c61
Add and use driver for communication over TCP. Driver uses two
...
threads, reader and writer, on a single socket. With this checkin a
connect request reaches the relay and a response comes back and is
passed to and recognized by the common code. A full game should now
work, but hasn't been tried. Nor is there any handling of socket
errors, retries, etc.
2005-07-30 02:02:49 +00:00
ehouse
19734cc053
begin work of allowing multi-device play over WiFi/Cellular: add
...
dialog to gather params, save 'em, and stub out send proc. Still need
to debug a bit, and add threads to send/receive packets.
2005-07-23 15:31:21 +00:00
ehouse
0a8b5bb563
Get rid of unused param
2005-07-14 02:54:47 +00:00
ehouse
6ca28e44e7
fix compile error
2005-07-13 12:35:38 +00:00
ehouse
7c4858887a
Refactor ce_dictionary_make so that it returns NULL rather than an
...
broken dict when the file's missing or corrupt. Casts to stop
warnings.
2005-06-30 01:48:07 +00:00
ehouse
61f86ae77d
util_setTimer changes
2005-06-23 14:09:20 +00:00
ehouse
5f0648c840
fix scrolling; resize board, enabling scrolling, when SIP is revealed.
...
And make it possible for user to reveal it.
2005-06-13 14:29:49 +00:00
ehouse
64876a008f
as a workaround for reported lockups on WM SE devices, save state
...
after many user actions. This was meant to capture the state right
before the crash but seems instead to have fixed it.
2005-02-06 06:56:06 +00:00
ehouse
132f7e808b
scrolling support; determine board layout based on screen size.
2005-02-05 21:43:16 +00:00
ehouse
c87132b416
remove dead param
2005-01-23 08:15:29 +00:00
ehouse
076e9917fb
fix to compile with changed api
2005-01-21 08:26:32 +00:00
ehouse
d8b00d98d3
remove unused vars
2005-01-04 15:11:00 +00:00
ehouse
fe5aec3785
use _vsnprintf to fix buffer overflow
2004-12-18 01:03:26 +00:00
ehouse
a07d8160f8
cover timer with scoreboard when no timer so region gets erased
2004-12-17 15:11:45 +00:00
ehouse
c0e2370cd2
init new-style menus
2004-12-17 07:45:30 +00:00
ehouse
218a0a9a1c
fix to compile without SEARCHLIMIT set
2004-12-11 04:25:45 +00:00
ehouse
4a9e05b277
catch up with api changes; add remaining tiles dialog
2004-11-09 02:40:36 +00:00