The main window was only positoned according to the settings-file data
after the engine was started up from InitBackend2(), so that if the
latter gave a fatal error, and Save Settings on Exit was on, a wrong
position for the main window would be saved. The call to InitBackend2()
is now moved until after setting the main-window position.
EngineOutputPopUp();\r
}\r
\r
- InitBackEnd2();\r
-\r
/* Make the window visible; update its client area; and return "success" */\r
EnsureOnScreen(&wpMain.x, &wpMain.y, minX, minY);\r
wp.length = sizeof(WINDOWPLACEMENT);\r
wp.rcNormalPosition.bottom = wpMain.y + wpMain.height;\r
SetWindowPlacement(hwndMain, &wp);\r
\r
+ InitBackEnd2(); // [HGM] moved until after all windows placed, to save correct position if fatal error on engine start\r
+\r
if(!appData.noGUI) SetWindowPos(hwndMain, alwaysOnTop ? HWND_TOPMOST : HWND_NOTOPMOST,\r
0, 0, 0, 0, SWP_NOMOVE|SWP_NOSIZE);\r
\r