Sophie

Sophie

distrib > Mandriva > 2009.0 > i586 > by-pkgid > 9e8230873ca69f393e5304ceb1afeac2 > files > 33

kdebase4-workspace-4.2.4-0.6mdv2009.0.src.rpm

# 
# SVN commit 937993 by sebsauer:
# 
# the backtrace from bug #186599 says this can happen. so, let's fix it
# the dirty way (dirty cause the assert means, that Applet::init got
# called more then once, hmmmmm....)
#

--- plasma/applets/kickoff/simpleapplet/simpleapplet.cpp~	2009-03-11 00:38:16.000000000 +0100
+++ plasma/applets/kickoff/simpleapplet/simpleapplet.cpp	2009-03-11 00:53:56.000000000 +0100
@@ -327,10 +327,11 @@
         connect(menueditor, SIGNAL(triggered(bool)), this, SLOT(startMenuEditor()));
     }
 
-    Q_ASSERT(! d->switcher);
-    d->switcher = new QAction(i18n("Switch to Kickoff Menu Style"), this);
-    d->actions.append(d->switcher);
-    connect(d->switcher, SIGNAL(triggered(bool)), this, SLOT(switchMenuStyle()));
+    if (! d->switcher) {
+        d->switcher = new QAction(i18n("Switch to Kickoff Menu Style"), this);
+        d->actions.append(d->switcher);
+        connect(d->switcher, SIGNAL(triggered(bool)), this, SLOT(switchMenuStyle()));
+    }
 
     Plasma::ToolTipManager::self()->registerWidget(this);
     d->updateTooltip();