┌   ┐
54
└   ┘

summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNate Graham <[email protected]>2020-11-17 12:13:30 -0700
committerNate Graham <[email protected]>2020-11-17 22:21:19 +0000
commitb76cc3f6fa2e94857a9168068e1ea10a4a0b6a2d (patch)
treecd5e7faa68c60968b3ff2c04d17a6040e1519a62
parentb03607b20b4dfb1e36378571e9157894f24a6ab5 (diff)
Separate Delete/Move To Trash menu items in context menu
Right now these actions are in a visual group with "Rename" and "Add to Places" which is silly as those actions have no logical connection whatsoever to deletion. This commits moves those items into the section above, putting them in a more logical place and leaving the Delete/Move To Trash item in its own section. BUG: 429256 FIXED-IN: 21.04
-rw-r--r--src/dolphincontextmenu.cpp22
1 files changed, 11 insertions, 11 deletions
diff --git a/src/dolphincontextmenu.cpp b/src/dolphincontextmenu.cpp
index dcf4b9b45..34d3127dc 100644
--- a/src/dolphincontextmenu.cpp
+++ b/src/dolphincontextmenu.cpp
@@ -271,15 +271,6 @@ void DolphinContextMenu::openItemContextMenu()
insertDefaultItemActions(selectedItemsProps);
- // insert 'Add to Places' entry if appropriate
- if (m_selectedItems.count() == 1) {
- if (m_fileInfo.isDir()) {
- if (!placeExists(m_fileInfo.url())) {
- addAction(m_mainWindow->actionCollection()->action(QStringLiteral("add_to_places")));
- }
- }
- }
-
addSeparator();
fileItemActions.addServiceActionsTo(this);
@@ -383,11 +374,20 @@ void DolphinContextMenu::insertDefaultItemActions(const KFileItemListProperties&
}
addAction(m_mainWindow->actionCollection()->action(QStringLiteral("duplicate")));
- addSeparator();
-
// Insert 'Rename'
addAction(collection->action(KStandardAction::name(KStandardAction::RenameFile)));
+ // insert 'Add to Places' entry if appropriate
+ if (m_selectedItems.count() == 1) {
+ if (m_fileInfo.isDir()) {
+ if (!placeExists(m_fileInfo.url())) {
+ addAction(m_mainWindow->actionCollection()->action(QStringLiteral("add_to_places")));
+ }
+ }
+ }
+
+ addSeparator();
+
// Insert 'Move to Trash' and/or 'Delete'
const bool showDeleteAction = (KSharedConfig::openConfig()->group("KDE").readEntry("ShowDeleteCommand", false) ||
!properties.isLocal());