File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -337,21 +337,17 @@ void MainWindow::loadWindowBounds()
337337 if (e->hasTagName (" BOUNDS" ))
338338 {
339339
340- int x = e->getIntAttribute (" x" );
341- int y = e->getIntAttribute (" y" );
342- int w = e->getIntAttribute (" w" );
343- int h = e->getIntAttribute (" h" );
344-
345- // bool fs = e->getBoolAttribute("fullscreen");
346-
347- // without the correction, you get drift over time
348- #ifdef _WIN32
349- setTopLeftPosition (x,y); // Windows doesn't need correction
350- #else
351- setTopLeftPosition (x,y-27 );
352- #endif
353- getContentComponent ()->setBounds (0 ,0 ,w-10 ,h-33 );
354- // setFullScreen(fs);
340+ String x = String (e->getIntAttribute (" x" ));
341+ String y = String (e->getIntAttribute (" y" ));
342+ String w = String (e->getIntAttribute (" w" ));
343+ String h = String (e->getIntAttribute (" h" ));
344+
345+ String windowBoundsString;
346+ windowBoundsString = x + " " + y + " " + w + " " + h;
347+
348+ LOGD (" Loading Window Bounds: " , windowBoundsString);
349+ restoreWindowStateFromString (windowBoundsString);
350+
355351 }
356352 else if (e->hasTagName (" RECENTDIRECTORYNAMES" ))
357353 {
You can’t perform that action at this time.
0 commit comments