Bug 74244 - switching desktops incurrs (seemingly) unrequired cpu load
Summary: switching desktops incurrs (seemingly) unrequired cpu load
Status: CLOSED FIXED
Alias: None
Product: kdesktop
Classification: Miscellaneous
Component: general (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR normal
Target Milestone: ---
Assignee: David Faure
URL:
Keywords:
: 69640 (view as bug list)
Depends on:
Blocks:
 
Reported: 2004-02-05 16:26 UTC by Daniel Quinn
Modified: 2009-01-02 20:27 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Daniel Quinn 2004-02-05 16:27:00 UTC
Version:           3.2.0 (using KDE 3.2.0, Gentoo)
Compiler:          gcc version 3.3.2 20040108 (Gentoo Linux 3.3.2-r6, propolice-3.3-7)
OS:          Linux (i686) release 2.4.22-gentoo-r3

when using the same large wallpaper (>1.5mb) on all 6 desktops, switching desktops is smooth, but almost immediately afterword, the cpu load jumps to 100% for about 1sec.  this is just enough to (a) make the mouse stutter while moving and/or (b) make my mp3's (via noatun) skip.  this is the case even when switching between two empty desktops.  this is more noticeable on my athlon800 than on my athlon2500, but still annoying ;-)

this only happens when i'm:
  running konsole with the dark/transparent schema on *any* desktop.  (ie konsole is on 3, and i'm switching between 5 & 6)
  using large wallpapers (though there is still a minimal load with no wallpaper.
Comment 1 Stephan Binner 2004-02-05 17:54:59 UTC
Simply don't use transparency, it relies on bad hacks.
Comment 2 Daniel Quinn 2004-02-05 18:12:35 UTC
if it's just a bunch of bad hacks, why then is it included in kde?
Comment 3 Stephan Binner 2004-02-05 18:41:41 UTC
People request it.
Comment 4 Lubos Lunak 2004-02-24 15:01:34 UTC
CVS commit by lunakl: 

Avoid attempts to repaint when virtual desktop changes and the widget
is not visible anyway.
CCMAIL: 74244-done@bugs.kde.org


  M +7 -0      krootpixmap.cpp   1.26


--- kdelibs/kdeui/krootpixmap.cpp  #1.25:1.26
@@ -20,4 +20,5 @@
 #include <kpixmapio.h>
 #include <kwinmodule.h>
+#include <kwin.h>
 #include <kdebug.h>
 #include <netwm.h>
@@ -159,4 +160,10 @@ bool KRootPixmap::eventFilter(QObject *,
 void KRootPixmap::desktopChanged( int )
 {
+    if( !m_pWidget->isVisible())
+        return; // not visible, no need to update
+    QWidget* widget = m_pWidget->topLevelWidget();
+    if( !widget->testWFlags( WX11BypassWM )
+        && !KWin::windowInfo( widget->winId(), NET::WMDesktop ).isOnCurrentDesktop())
+        return; // not on current desktop -> not visible, no need to update
     repaint(true);
 }


Comment 5 Lubos Lunak 2004-03-11 18:29:11 UTC
*** Bug 69640 has been marked as a duplicate of this bug. ***
Comment 6 FiNeX 2009-01-02 20:27:00 UTC
Bug closed. Kdesktop is no more mantained.