From: jacob Date: Sat, 3 Mar 2007 23:17:35 +0000 (+0000) Subject: Patch from Ben Hutchings to allow user-initiated tilesize changes to persist X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/puzzles/commitdiff_plain/888050f2206455bfe5f1470dd38e19b6cfc69b65 Patch from Ben Hutchings to allow user-initiated tilesize changes to persist across changes in game parameters (e.g., changing difficulty without changing size). This also has the effect of preserving the user-selected tilesize if the grid size is changed. (From Debian bug#379452.) git-svn-id: svn://svn.tartarus.org/sgt/puzzles@7368 cda61777-01e9-0310-a592-d414129be87e --- diff --git a/midend.c b/midend.c index 779ca0c..d0bc950 100644 --- a/midend.c +++ b/midend.c @@ -264,6 +264,8 @@ void midend_size(midend *me, int *x, int *y, int expand) */ me->tilesize = min; + if (expand) + me->preferred_tilesize = me->tilesize; midend_size_new_drawstate(me); *x = me->winwidth; *y = me->winheight;