]> git.lyx.org Git - features.git/commitdiff
remove warning, use shorter code
authorPeter Kümmel <syntheticpp@gmx.net>
Sat, 28 Oct 2006 17:14:51 +0000 (17:14 +0000)
committerPeter Kümmel <syntheticpp@gmx.net>
Sat, 28 Oct 2006 17:14:51 +0000 (17:14 +0000)
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@15595 a592a061-630c-0410-9148-cb99ea01b6c8

src/frontends/qt4/GuiView.C

index 319a44291d95bd76650eacd9e35eebd0f0705d1b..d9b65427d5ccac22f63784ca5abed88282460949 100644 (file)
@@ -160,10 +160,8 @@ void GuiView::setGeometry(unsigned int width,
                        // http://doc.trolltech.com/4.2/qdesktopwidget.html 
                        QDesktopWidget& dw = *qApp->desktop();
                        QRect desk = dw.availableGeometry(dw.primaryScreen());
-                       if (posx >= desk.width())
-                                  posx = 0.1 * desk.width();
-                       if (posy >= desk.height())
-                                  posy = 0.1 * desk.height();
+                       (posx >= desk.width() ? posx = 50 : true);
+                       (posy >= desk.height()? posy = 50 : true);
 #ifdef Q_WS_WIN
                        // FIXME: use only setGeoemtry when Trolltech has
                        // fixed the qt4/X11 bug