Op 4/12/2016 om 3:20 PM schreef Adrian Petrescu:
* Adding if(dlgNr == BoardWindow) DelayedDrag(); to the end of
GenericPopUp() (in gtk/xoptions.c) still makes the board small,
*but* it does result in the following prints as soon as xboard is
launched:
resize: new 958x1043 @ (960,18) old -1x1043 @ (960,18)
resize: new 958x1043 @ (960,18) old -1x1043 @ (960,18)
resize: new 958x1043 @ (960,18) old 958x1043 @ (960,18)
I just noticed something: At the beginning of ReSize there is a
declaration "static int first=1".
This suppresses any square resizing on the first call to Resize(). What
happens when you change that into first=0 ?
That would be a third explanation for why ReSize did not do anything,
even though the above output shows it was called.
I must admit that I do not understand why resizing then did not occur on
the second call, which still has new and old width different.
But in fact I do not really understand how there could be a second call
to DragProc where the old width (from wpMain) was -1.
Because in DragProg there is a statemet wpMain = wpNew, which should
have copied the 958 in wpNew over the -1 in wpMain.
So it should not be possible that DragProg is called a second time with
wpMain.width == -1. Unless it was called recursively,
between printing the above line and the wpMain = wpNew, but the busy=1
construction is supposed to make that impossible.
But anyway, trying the first=0 seems worth the attempt, in combination
with the above extra call to DeleyedDrag().
H.G.