Work-around for bug #6034: Applying preferences confuses window about its size.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@30897 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Vincent van Ravesteijn 2009-08-07 12:49:03 +00:00
parent 89e7f60e1d
commit a43e6129eb

View File

@ -387,8 +387,12 @@ bool GuiView::restoreLayout()
resize(size); resize(size);
move(pos); move(pos);
#else #else
if (!restoreGeometry(settings.value("geometry").toByteArray())) // Work-around for bug #6034: the window ends up in an undetermined
setGeometry(50, 50, 690, 510); // state when trying to restore a maximized window when it is
// already maximized.
if (!(windowState() & Qt::WindowMaximized))
if (!restoreGeometry(settings.value("geometry").toByteArray()))
setGeometry(50, 50, 690, 510);
#endif #endif
// Make sure layout is correctly oriented. // Make sure layout is correctly oriented.
setLayoutDirection(qApp->layoutDirection()); setLayoutDirection(qApp->layoutDirection());