Commit f9f3f6ca authored by Nate Graham's avatar Nate Graham 🔩

Use Standard "Show/Hide Hidden files" shortcuts in directory chooser dialog

Summary:
New standard shortcuts were added in D28802 and adopting them replaces the fairly random
F8 shortcut here.

CCBUG: 262551

Depends on D28802

Test Plan:
Open directory chooser dialog from the {nav Add Folder} button in the plasma slideshow
wallpaper dialog and hit Ctrl+H or Alt+.

Reviewers: #plasma, #frameworks, ndavis

Reviewed By: ndavis

Subscribers: plasma-devel

Tags: #plasma

Differential Revision: https://phabricator.kde.org/D29238
parent f30c8ca7
......@@ -5,7 +5,7 @@ set(PROJECT_VERSION "5.18.80")
set(PROJECT_VERSION_MAJOR 5)
set(QT_MIN_VERSION "5.14.0")
set(KF5_MIN_VERSION "5.66.0")
set(KF5_MIN_VERSION "5.70.0")
find_package(ECM ${KF5_MIN_VERSION} REQUIRED NO_MODULE)
set(CMAKE_MODULE_PATH ${CMAKE_CURRENT_SOURCE_DIR}/cmake/modules ${ECM_MODULE_PATH} ${ECM_KDE_MODULE_DIR})
......
......@@ -55,6 +55,7 @@
#include <kurlpixmapprovider.h>
#include <kfilewidget.h>
#include <KFileUtils>
#include <KStandardShortcut>
#include "kfiletreeview_p.h"
#include <kfileplacesview.h>
......@@ -368,7 +369,7 @@ KDirSelectDialog::KDirSelectDialog(const QUrl &startDir, bool localOnly, QWidget
d->showHiddenFoldersAction = new KToggleAction(i18nc("@option:check", "Show Hidden Folders"), this);
d->m_actions->addAction(d->showHiddenFoldersAction->objectName(), d->showHiddenFoldersAction);
d->showHiddenFoldersAction->setShortcut(Qt::Key_F8);
d->showHiddenFoldersAction->setShortcuts(KStandardShortcut::showHideHiddenFiles());
connect(d->showHiddenFoldersAction, &QAction::triggered, d->m_treeView, &KFileTreeView::setShowHiddenFiles);
d->m_contextMenu->addAction(d->showHiddenFoldersAction);
d->m_contextMenu->addSeparator();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment