X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/4b5ea05b6760e9020ab87f1d90071e1a2a8f9e99..5454283008f2:/src/dolphincontextmenu.cpp diff --git a/src/dolphincontextmenu.cpp b/src/dolphincontextmenu.cpp index 7ee9562ae..b4d249d76 100644 --- a/src/dolphincontextmenu.cpp +++ b/src/dolphincontextmenu.cpp @@ -124,7 +124,7 @@ DolphinContextMenu::Command DolphinContextMenu::open() void DolphinContextMenu::keyPressEvent(QKeyEvent *ev) { if (m_removeAction && ev->key() == Qt::Key_Shift) { - m_removeAction->update(); + m_removeAction->update(DolphinRemoveAction::ShiftState::Pressed); } QMenu::keyPressEvent(ev); } @@ -132,7 +132,7 @@ void DolphinContextMenu::keyPressEvent(QKeyEvent *ev) void DolphinContextMenu::keyReleaseEvent(QKeyEvent *ev) { if (m_removeAction && ev->key() == Qt::Key_Shift) { - m_removeAction->update(); + m_removeAction->update(DolphinRemoveAction::ShiftState::Released); } QMenu::keyReleaseEvent(ev); } @@ -392,8 +392,7 @@ void DolphinContextMenu::insertDefaultItemActions(const KFileItemListProperties& addSeparator(); // Insert 'Rename' - QAction* renameAction = collection->action(QStringLiteral("rename")); - addAction(renameAction); + addAction(collection->action(KStandardAction::name(KStandardAction::RenameFile))); // Insert 'Move to Trash' and/or 'Delete' if (properties.supportsDeleting()) {