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

List:       kde-commits
Subject:    KDE/kdebase/workspace/plasma/desktop/applets/tasks
From:       Aaron J. Seigo <aseigo () kde ! org>
Date:       2011-01-19 22:31:42
Message-ID: 20110119223142.59BA4AC8B7 () svn ! kde ! org
[Download RAW message or body]

SVN commit 1215864 by aseigo:

don't bother checking status, etc. of the root group; it doesn't need to update \
itself, so is just wasted cycles (cycles triggered on every window change, not to \
mention triggerng full widget repaints)


 M  +6 -2      taskgroupitem.cpp  
 M  +1 -0      taskgroupitem.h  


--- trunk/KDE/kdebase/workspace/plasma/desktop/applets/tasks/taskgroupitem.cpp \
#1215863:1215864 @@ -198,10 +198,14 @@
     }
 }
 
+bool TaskGroupItem::isRootGroup() const
+{
+    return m_applet == parentWidget();
+}
 
 void TaskGroupItem::updateTask(::TaskManager::TaskChanges changes)
 {
-    if (!m_group) {
+    if (!m_group || isRootGroup()) {
         return;
     }
 
@@ -405,7 +409,7 @@
 
     Q_ASSERT(m_applet);
     //we are the master group item
-    if (m_applet == parentWidget()) {
+    if (isRootGroup()) {
         e->ignore();
         return;
     }
--- trunk/KDE/kdebase/workspace/plasma/desktop/applets/tasks/taskgroupitem.h \
#1215863:1215864 @@ -155,6 +155,7 @@
     virtual void wheelEvent(QGraphicsSceneWheelEvent *event);
 
 private Q_SLOTS:
+    bool isRootGroup() const;
     void checkUpdates();
     void constraintsChanged(Plasma::Constraints);
     void handleActiveWindowChanged(WId id);


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

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