aboutsummaryrefslogtreecommitdiff
path: root/nestedvm.c
diff options
context:
space:
mode:
authorSimon Tatham <anakin@pobox.com>2023-04-23 14:58:31 +0100
committerSimon Tatham <anakin@pobox.com>2023-04-23 14:58:31 +0100
commitf01b1674bd862e1792b5216bd5d832cd52a170ae (patch)
tree08463cfcd00655b6c4e4b8f355bb37f60b33cddc /nestedvm.c
parent1fa28340e8e8d8459456469c72f7156ccf1493f1 (diff)
downloadpuzzles-f01b1674bd862e1792b5216bd5d832cd52a170ae.zip
puzzles-f01b1674bd862e1792b5216bd5d832cd52a170ae.tar.gz
puzzles-f01b1674bd862e1792b5216bd5d832cd52a170ae.tar.bz2
puzzles-f01b1674bd862e1792b5216bd5d832cd52a170ae.tar.xz
GTK: stop referring to &thegame in prefs I/O functions.
I had to do this in the Windows front end to cope with compiling in both COMBINED and one-puzzle mode: you can't refer to &thegame because it might not exist in this build, so instead, if you want to load/save preferences for a given midend, you ask that midend for _its_ game structure, and use that to make the necessary file names. On Unix, we don't have COMBINED mode. But now I've thought of it, this seems like a good idiom anyway, for the sake of futureproofing against the day someone decides to implement combined mode on Unix. delete_prefs() doesn't get passed a frontend _or_ a midend, so that just has to take a bare 'const game *' parameter, and in main() we pass &thegame to it. So that will still need changing in a combined mode, if one is ever added.
Diffstat (limited to 'nestedvm.c')
0 files changed, 0 insertions, 0 deletions