X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/86ac2e51eab9ba3412cbaf655bcc27f20b419157..d57990e681397d3dc2d2ebf737eced730dd3ecf7:/src/dolphincontextmenu.cpp diff --git a/src/dolphincontextmenu.cpp b/src/dolphincontextmenu.cpp index 8372060aa..e1c67aad1 100644 --- a/src/dolphincontextmenu.cpp +++ b/src/dolphincontextmenu.cpp @@ -122,7 +122,7 @@ void DolphinContextMenu::addTrashContextMenu() { Q_ASSERT(m_context & TrashContext); - QAction *emptyTrashAction = addAction(QIcon::fromTheme(QStringLiteral("edit-delete")), i18nc("@action:inmenu", "Empty Trash"), [this]() { + QAction *emptyTrashAction = addAction(QIcon::fromTheme(QStringLiteral("edit-delete")), i18nc("@action:inmenu", "Empty Trash"), this, [this]() { Trash::empty(m_mainWindow); }); emptyTrashAction->setEnabled(!Trash::isEmpty()); @@ -154,6 +154,7 @@ void DolphinContextMenu::addTrashItemContextMenu() "Restore to Former Location", "Restore to Former Locations", m_selectedItems.count()), + this, [this]() { QList selectedUrls; selectedUrls.reserve(m_selectedItems.count()); @@ -202,7 +203,7 @@ void DolphinContextMenu::addDirectoryItemContextMenu() // set up 'Create New' menu QAction *newDirAction = m_mainWindow->actionCollection()->action(QStringLiteral("create_dir")); QAction *newFileAction = m_mainWindow->actionCollection()->action(QStringLiteral("create_file")); - DolphinNewFileMenu *newFileMenu = new DolphinNewFileMenu(newDirAction, newFileAction, m_mainWindow); + DolphinNewFileMenu *newFileMenu = new DolphinNewFileMenu(newDirAction, newFileAction, this); newFileMenu->checkUpToDate(); newFileMenu->setWorkingDirectory(m_fileInfo.url()); newFileMenu->setEnabled(selectedItemsProps.supportsWriting());