From a512176b4bdbf0f0471a9b9089f4a936c14e2732 Mon Sep 17 00:00:00 2001 From: Duong Do Minh Chau Date: Thu, 12 Nov 2020 16:38:44 +0700 Subject: Add options to hide some context menu entries This commit add options to hide the following context menu entries: - Add to Places - Copy Location - Duplicate Here - Open in New Tab and Open in New Tabs - Open in New Window - Sort By - View Mode The Services settings page is renamed to Context Menu ShowCopyMoveMenu option is moved from GeneralSettings to ContextMenuSettings BUG: 314594 --- src/settings/dolphinsettingsdialog.cpp | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'src/settings/dolphinsettingsdialog.cpp') diff --git a/src/settings/dolphinsettingsdialog.cpp b/src/settings/dolphinsettingsdialog.cpp index 9d8fb032a..01d0ad030 100644 --- a/src/settings/dolphinsettingsdialog.cpp +++ b/src/settings/dolphinsettingsdialog.cpp @@ -10,7 +10,7 @@ #include "dolphinmainwindow.h" #include "general/generalsettingspage.h" #include "navigation/navigationsettingspage.h" -#include "services/servicessettingspage.h" +#include "contextmenu/contextmenusettingspage.h" #include "startup/startupsettingspage.h" #include "trash/trashsettingspage.h" #include "viewmodes/viewsettingspage.h" @@ -77,12 +77,12 @@ DolphinSettingsDialog::DolphinSettingsDialog(const QUrl& url, QWidget* parent) : navigationSettingsFrame->setIcon(QIcon::fromTheme(QStringLiteral("preferences-desktop-navigation"))); connect(navigationSettingsPage, &NavigationSettingsPage::changed, this, &DolphinSettingsDialog::enableApply); - // Services - ServicesSettingsPage* servicesSettingsPage = new ServicesSettingsPage(this); - KPageWidgetItem* servicesSettingsFrame = addPage(servicesSettingsPage, - i18nc("@title:group", "Services")); - servicesSettingsFrame->setIcon(QIcon::fromTheme(QStringLiteral("preferences-system-services"))); - connect(servicesSettingsPage, &ServicesSettingsPage::changed, this, &DolphinSettingsDialog::enableApply); + // Context Menu + auto contextMenuSettingsPage = new ContextMenuSettingsPage(this); + KPageWidgetItem* contextMenuSettingsFrame = addPage(contextMenuSettingsPage, + i18nc("@title:group", "Context Menu")); + contextMenuSettingsFrame->setIcon(QIcon::fromTheme(QStringLiteral("application-menu"))); + connect(contextMenuSettingsPage, &ContextMenuSettingsPage::changed, this, &DolphinSettingsDialog::enableApply); // Trash SettingsPageBase* trashSettingsPage = nullptr; @@ -111,7 +111,7 @@ DolphinSettingsDialog::DolphinSettingsDialog(const QUrl& url, QWidget* parent) : m_pages.append(startupSettingsPage); m_pages.append(viewSettingsPage); m_pages.append(navigationSettingsPage); - m_pages.append(servicesSettingsPage); + m_pages.append(contextMenuSettingsPage); if (trashSettingsPage) { m_pages.append(trashSettingsPage); } -- cgit v1.3