Don't crash if d->toolBox is NULL.

"plasmoidviewer desktop" works now too :)

svn path=/trunk/KDE/kdebase/workspace/libs/plasma/; revision=836717
This commit is contained in:
Sebastian Sauer 2008-07-22 20:46:34 +00:00
parent 5e5622ddf2
commit 19e5356bf5

View File

@ -191,7 +191,7 @@ void Containment::init()
activityAction->setShortcut(QKeySequence("ctrl+shift+a"));
d->actions().addAction("add sibling containment", activityAction);
if (d->type == DesktopContainment) {
if (d->type == DesktopContainment && d->toolBox) {
d->toolBox->addTool(this->action("add widgets"));
d->toolBox->addTool(this->action("zoom in"));
d->toolBox->addTool(this->action("zoom out"));