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

List:       kde-commits
Subject:    kdebase/kicker/taskmanager
From:       Aaron J. Seigo <aseigo () kde ! org>
Date:       2005-04-19 7:01:30
Message-ID: 20050419070130.F41545FA () office ! kde ! org
[Download RAW message or body]

CVS commit by aseigo: 

take another run at treating NET::WMName more efficiently. we still don't
cause redraws with every keystroke, but do watch for things like [modified]
appearing. why is X such a series of inane hacks?


  M +15 -8     taskmanager.cpp   1.99
  M +1 -1      taskmanager.h   1.66


--- kdebase/kicker/taskmanager/taskmanager.cpp  #1.98:1.99
@@ -266,5 +266,5 @@ void TaskManager::windowChanged(WId w, u
 
     // check if any state we are interested in is marked dirty
-    if(!(dirty & (NET::WMVisibleName | NET::WMVisibleIconName |
+    if (!(dirty & (NET::WMVisibleName | NET::WMVisibleIconName | NET::WMName |
                   NET::WMIconName | NET::WMState | NET::WMIcon |
                   NET::XAWMState | NET::WMDesktop) ||
@@ -280,6 +280,8 @@ void TaskManager::windowChanged(WId w, u
     //kdDebug() << "TaskManager::windowChanged " << w << " " << dirty << endl;
 
-    if( dirty & NET::WMState )
+    if (dirty & NET::WMState)
+    {
         t->updateDemandsAttentionState( w );
+    }
 
     // refresh icon pixmap if necessary
@@ -292,5 +294,5 @@ void TaskManager::windowChanged(WId w, u
     {
         // only refresh this stuff if we have other changes besides icons
-        t->refresh();
+        t->refresh(dirty);
     }
 
@@ -509,8 +511,13 @@ void Task::refreshIcon()
 }
 
-void Task::refresh()
+void Task::refresh(unsigned int dirty)
 {
+    QString name = visibleIconicName();
     _info = KWin::windowInfo(_win);
+
+    if (dirty ^ NET::WMName || name != visibleIconicName())
+    {
     emit changed();
+    }
 }
 

--- kdebase/kicker/taskmanager/taskmanager.h  #1.65:1.66
@@ -237,5 +237,5 @@ public:
 
     //* @internal
-    void refresh();
+    void refresh(unsigned int dirty);
     //* @internal
     void refreshIcon();


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

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