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

List:       kde-commits
Subject:    kdereview/plasma/applets/incomingmsg
From:       Aaron J. Seigo <aseigo () kde ! org>
Date:       2008-09-30 16:54:56
Message-ID: 1222793696.563816.20829.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 866356 by aseigo:

only do geometry when geometry changes; still incorrect though =)


 M  +8 -7      incomingmsg.cpp  


--- trunk/kdereview/plasma/applets/incomingmsg/incomingmsg.cpp #866355:866356
@@ -354,13 +354,14 @@
 
 void IncomingMsg::constraintsEvent(Plasma::Constraints constraints)
 {
-    Q_UNUSED(constraints);
-    setBackgroundHints(Plasma::Applet::DefaultBackground);
-    QRectF layoutRectF = mLayout->geometry();
-    QRectF appletRectF = geometry();
-    if (layoutRectF.height() > appletRectF.height()) {
-        appletRectF.setHeight(layoutRectF.height() + 10);
-        setGeometry(appletRectF);
+    if (mLayout && (constraints & Plasma::SizeConstraint ||
+                    constraints & Plasma::FormFactorConstraint)) {
+        QRectF layoutRectF = mLayout->geometry();
+        QRectF appletRectF = geometry();
+        if (layoutRectF.height() > appletRectF.height()) {
+            appletRectF.setHeight(layoutRectF.height() + 10);
+            setGeometry(appletRectF);
+        }
     }
 }
 
[prev in list] [next in list] [prev in thread] [next in thread] 

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