]> cloud.milkyroute.net Git - dolphin.git/commitdiff
Separate the parent object (for the knewfilemenu instance) and the parent widget
authorDavid Faure <faure@kde.org>
Mon, 8 Feb 2010 14:27:58 +0000 (14:27 +0000)
committerDavid Faure <faure@kde.org>
Mon, 8 Feb 2010 14:27:58 +0000 (14:27 +0000)
(for dialogs it might pop up) so that we can use a non-widget parent.
BUG: 218743

svn path=/trunk/KDE/kdebase/apps/; revision=1087087

src/dolphinpart.cpp

index e005ac29c21ff1a8ce95d10d36c2ee62eed212b6..e5151c0fbc602b8e476f35feb879eb32af8d3d45 100644 (file)
@@ -156,7 +156,8 @@ void DolphinPart::createActions()
 {
     // Edit menu
 
 {
     // Edit menu
 
-    m_newMenu = new KNewFileMenu(actionCollection(), "new_menu", widget());
+    m_newMenu = new KNewFileMenu(actionCollection(), "new_menu", this);
+    m_newMenu->setParentWidget(widget());
     DolphinNewMenuObserver::instance().attach(m_newMenu);
     connect(m_newMenu->menu(), SIGNAL(aboutToShow()),
             this, SLOT(updateNewMenu()));
     DolphinNewMenuObserver::instance().attach(m_newMenu);
     connect(m_newMenu->menu(), SIGNAL(aboutToShow()),
             this, SLOT(updateNewMenu()));