@@ -88,25 +88,25 @@ struct SelectGameWindow : public Window
if (widget != SGI_DIFFICULTIES) return;
Dimension textdim = {0, 0};
for (uint i = STR_DIFFICULTY_LEVEL_EASY; i <= STR_DIFFICULTY_LEVEL_CUSTOM; i++) {
SetDParam(0, i);
textdim = maxdim(textdim, GetStringBoundingBox(STR_INTRO_DIFFICULTY));
}
textdim.width += padding.width;
textdim.height += padding.height;
*size = maxdim(*size, textdim);
virtual void OnClick(Point pt, int widget)
virtual void OnClick(Point pt, int widget, int click_count)
{
#ifdef ENABLE_NETWORK
/* Do not create a network server when you (just) have closed one of the game
* creation/load windows for the network server. */
if (IsInsideMM(widget, SGI_GENERATE_GAME, SGI_EDIT_SCENARIO + 1)) _is_network_server = false;
#endif /* ENABLE_NETWORK */
switch (widget) {
case SGI_GENERATE_GAME:
if (_ctrl_pressed) {
StartNewGameWithoutGUI(GENERATE_NEW_SEED);
} else {