]> cloud.milkyroute.net Git - dolphin.git/blobdiff - src/dolphinmainwindow.cpp
Special case file opening with middle click for executable scripts
[dolphin.git] / src / dolphinmainwindow.cpp
index fd1c6f02083de60e2f6ae9adcfd094f46a463466..afb86e1522121971018639bc07339979c44048a4 100644 (file)
@@ -629,7 +629,7 @@ void DolphinMainWindow::closeEvent(QCloseEvent *event)
             QStringList(),
             i18n("Do not ask again"),
             &doNotAskAgainCheckboxResult,
-            KMessageBox::Dangerous);
+            KMessageBox::Notify | KMessageBox::Dangerous);
 
         if (doNotAskAgainCheckboxResult) {
             GeneralSettings::setConfirmClosingTerminalRunningProgram(false);
@@ -1189,11 +1189,12 @@ void DolphinMainWindow::openTerminalHere()
             {},
 #endif
             KGuiItem(i18ncp("@action:button", "Open %1 Terminal", "Open %1 Terminals", urls.count()), QStringLiteral("utilities-terminal")),
-            KStandardGuiItem::cancel());
+            KStandardGuiItem::cancel(),
+            QStringLiteral("ConfirmOpenManyTerminals"));
 #if KWIDGETSADDONS_VERSION >= QT_VERSION_CHECK(5, 100, 0)
-        if (answer != KMessageBox::PrimaryAction) {
+        if (answer != KMessageBox::PrimaryAction && answer != KMessageBox::Continue) {
 #else
-        if (answer != KMessageBox::Yes) {
+        if (answer != KMessageBox::Yes && answer != KMessageBox::Continue) {
 #endif
             return;
         }
@@ -1800,7 +1801,7 @@ void DolphinMainWindow::setupActions()
     replaceLocation->setWhatsThis(xi18nc("@info:whatsthis",
                                          "This switches to editing the location and selects it "
                                          "so you can quickly enter a different location."));
-    actionCollection()->setDefaultShortcut(replaceLocation, Qt::CTRL | Qt::Key_L);
+    actionCollection()->setDefaultShortcuts(replaceLocation, {Qt::CTRL | Qt::Key_L, Qt::ALT | Qt::Key_D});
     connect(replaceLocation, &QAction::triggered, this, &DolphinMainWindow::replaceLocation);
 
     // setup 'Go' menu
@@ -2698,3 +2699,5 @@ bool DolphinMainWindow::isItemVisibleInAnyView(const QString &urlOfItem)
 {
     return m_tabWidget->isItemVisibleInAnyView(QUrl::fromUserInput(urlOfItem));
 }
+
+#include "moc_dolphinmainwindow.cpp"