[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    KDE/kdebase/apps/plasma/applets/folderview
From:       Aaron J. Seigo <aseigo () kde ! org>
Date:       2010-02-04 18:42:38
Message-ID: 1265308958.137078.19810.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 1085254 by aseigo:

really rather ugly, but we really can't be using QDesktopWidget here as it's broken \
on far too many multi-screen setups


 M  +11 -1     folderview.cpp  


--- trunk/KDE/kdebase/apps/plasma/applets/folderview/folderview.cpp #1085253:1085254
@@ -1153,8 +1153,18 @@
     if (!c) {
         return;
     }
+
     const QRect screenRect = c->screenGeometry(screen());
-    const QRect availRect = QApplication::desktop()->availableGeometry(screen());
+    QRect availRect;
+    //FIXME: a pretty horrible hack, but there we go; should do something more \
elegant in 4.5 +    if (c->metaObject()->indexOfSlot("availableScreenRect(int)") != \
-1) { +        QMetaObject::invokeMethod(c, "availableScreenRect",
+                                  Qt::DirectConnection, Q_RETURN_ARG(QRect, \
availRect), Q_ARG(int, screen())); +    } else {
+        kDebug() << "using qdesktopwidget";
+        availRect = QApplication::desktop()->availableGeometry(screen());
+    }
+
     m_iconView->setContentsMargins(availRect.x() - screenRect.x(),
                                    availRect.y() - screenRect.y(),
                                    screenRect.right() - availRect.right(),


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic