┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
path: root/src/dolphinmainwindow.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/dolphinmainwindow.cpp')
-rw-r--r--src/dolphinmainwindow.cpp19
1 files changed, 18 insertions, 1 deletions
diff --git a/src/dolphinmainwindow.cpp b/src/dolphinmainwindow.cpp
index 9a5e5e3a8..1c1343976 100644
--- a/src/dolphinmainwindow.cpp
+++ b/src/dolphinmainwindow.cpp
@@ -1184,7 +1184,24 @@ void DolphinMainWindow::openContextMenu(const KFileItem& item,
{
DolphinContextMenu contextMenu(this, item, url);
contextMenu.setCustomActions(customActions);
- contextMenu.open();
+ const DolphinContextMenu::Command command = contextMenu.open();
+
+ switch (command) {
+ case DolphinContextMenu::OpenParentFolderInNewWindow: {
+ DolphinMainWindow* window = DolphinApplication::app()->createMainWindow();
+ window->changeUrl(item.url().upUrl());
+ window->show();
+ break;
+ }
+
+ case DolphinContextMenu::OpenParentFolderInNewTab:
+ openNewTab(item.url().upUrl());
+ break;
+
+ case DolphinContextMenu::None:
+ default:
+ break;
+ }
}
void DolphinMainWindow::init()