X-Git-Url: https://cloud.milkyroute.net/gitweb/dolphin.git/blobdiff_plain/15e0c2a98f480f203ce168b6fa9a2e1f2b0ed8f8..fe56127d9e90c2b364189d38ea43c64ee2019874:/src/dolphincontextmenu.cpp diff --git a/src/dolphincontextmenu.cpp b/src/dolphincontextmenu.cpp index 84023ddbd..413ab96a0 100644 --- a/src/dolphincontextmenu.cpp +++ b/src/dolphincontextmenu.cpp @@ -147,28 +147,36 @@ void DolphinContextMenu::addTrashItemContextMenu() Q_ASSERT(m_context & TrashContext); Q_ASSERT(m_context & ItemContext); - addAction(QIcon::fromTheme("restoration"), i18nc("@action:inmenu", "Restore"), [this]() { - QList selectedUrls; - selectedUrls.reserve(m_selectedItems.count()); - for (const KFileItem &item : std::as_const(m_selectedItems)) { - selectedUrls.append(item.url()); - } - - KIO::RestoreJob *job = KIO::restoreFromTrash(selectedUrls); - KJobWidgets::setWindow(job, m_mainWindow); - job->uiDelegate()->setAutoErrorHandlingEnabled(true); - }); + addAction(QIcon::fromTheme(QStringLiteral("edit-reset")), + i18ncp("@action:inmenu Restore the selected files that are in the trash to the place they lived at the moment they were trashed. Minimize the " + "length of this string if possible.", + "Restore to Former Location", + "Restore to Former Locations", + m_selectedItems.count()), + [this]() { + QList selectedUrls; + selectedUrls.reserve(m_selectedItems.count()); + for (const KFileItem &item : std::as_const(m_selectedItems)) { + selectedUrls.append(item.url()); + } + + KIO::RestoreJob *job = KIO::restoreFromTrash(selectedUrls); + KJobWidgets::setWindow(job, m_mainWindow); + job->uiDelegate()->setAutoErrorHandlingEnabled(true); + }); - QAction *deleteAction = m_mainWindow->actionCollection()->action(KStandardAction::name(KStandardAction::DeleteFile)); - addAction(deleteAction); + QAction *propertiesAction = m_mainWindow->actionCollection()->action(QStringLiteral("properties")); + addAction(propertiesAction); addSeparator(); + addAction(m_mainWindow->actionCollection()->action(KStandardAction::name(KStandardAction::Cut))); addAction(m_mainWindow->actionCollection()->action(KStandardAction::name(KStandardAction::Copy))); addSeparator(); - QAction *propertiesAction = m_mainWindow->actionCollection()->action(QStringLiteral("properties")); - addAction(propertiesAction); + + QAction *deleteAction = m_mainWindow->actionCollection()->action(KStandardAction::name(KStandardAction::DeleteFile)); + addAction(deleteAction); } void DolphinContextMenu::addDirectoryItemContextMenu()