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

List:       kde-commits
Subject:    kdelibs/kdeui
From:       Richard J. Moore <rich () kde ! org>
Date:       2003-09-30 22:14:28
[Download RAW message or body]

CVS commit by rich: 

KRootPixmap had a bug in that it didn't update the background when the user
changed desktops. This patch forces a repaint whenever the current desktop
changes which solves the problem.


  M +9 -1      krootpixmap.cpp   1.23
  M +3 -2      krootpixmap.h   1.27


--- kdelibs/kdeui/krootpixmap.cpp  #1.22:1.23
@@ -32,4 +32,5 @@ class KRootPixmapData
 public:
     QWidget *toplevel;
+    KWinModule *kwin;
 };
 
@@ -61,4 +62,7 @@ void KRootPixmap::init()
     connect(m_pTimer, SIGNAL(timeout()), SLOT(repaint()));
 
+    d->kwin = new KWinModule( this );
+    connect( d->kwin, SIGNAL(currentDesktopChanged(int)), SLOT(desktopChanged(int)) );
+
     d->toplevel = m_pWidget->topLevelWidget();
     d->toplevel->installEventFilter(this);
@@ -154,4 +158,8 @@ bool KRootPixmap::eventFilter(QObject *,
 }
 
+void KRootPixmap::desktopChanged( int desk )
+{
+    repaint(true);
+}
 
 void KRootPixmap::repaint()

--- kdelibs/kdeui/krootpixmap.h  #1.26:1.27
@@ -193,4 +193,5 @@ private slots:
     void slotBackgroundChanged(int);
     void slotDone(bool);
+    void desktopChanged( int desk );
 
 private:


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

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