From d43e033743f603e5fb1bcc3ae7abf77e8682d1a9 Mon Sep 17 00:00:00 2001 From: dail8859 Date: Tue, 11 Jun 2024 22:06:47 -0400 Subject: [PATCH] Remove "action" prefix when specifying action names for tab bar --- src/NotepadNext/dialogs/MainWindow.cpp | 28 +++++++++++++------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/src/NotepadNext/dialogs/MainWindow.cpp b/src/NotepadNext/dialogs/MainWindow.cpp index 38c4e7924..8f5d0ed24 100644 --- a/src/NotepadNext/dialogs/MainWindow.cpp +++ b/src/NotepadNext/dialogs/MainWindow.cpp @@ -1986,25 +1986,25 @@ void MainWindow::tabBarRightClicked(ScintillaNext *editor) // Default actions QStringList actionNames{ - "actionClose", - "actionCloseAllExceptActive", - "actionCloseAllToLeft", - "actionCloseAllToRight", + "Close", + "CloseAllExceptActive", + "CloseAllToLeft", + "CloseAllToRight", "", - "actionSave", - "actionSaveAs", - "actionRename", + "Save", + "SaveAs", + "Rename", "", - "actionReload", + "Reload", "", #ifdef Q_OS_WIN - "actionShowInExplorer", - "actionOpenCommandPromptHere", + "ShowInExplorer", + "OpenCommandPromptHere", "", #endif - "actionCopyFullPath", - "actionCopyFileName", - "actionCopyFileDirectory" + "CopyFullPath", + "CopyFileName", + "CopyFileDirectory" }; // If the entry exists in the settings, use that @@ -2019,7 +2019,7 @@ void MainWindow::tabBarRightClicked(ScintillaNext *editor) menu->addSeparator(); } else { - QAction *a = findChild(actionName, Qt::FindDirectChildrenOnly); + QAction *a = findChild(QStringLiteral("action") + actionName, Qt::FindDirectChildrenOnly); if (a != Q_NULLPTR) { menu->addAction(a);