effects/windowview: Add ExposeClassCurrentDesktop shortcut to KCM
See also: f2defd1dfa
This commit is contained in:
parent
105af544c9
commit
e45cc7a807
1 changed files with 7 additions and 0 deletions
|
@ -1,5 +1,6 @@
|
||||||
/*
|
/*
|
||||||
SPDX-FileCopyrightText: 2021 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
|
SPDX-FileCopyrightText: 2021 Vlad Zahorodnii <vlad.zahorodnii@kde.org>
|
||||||
|
SPDX-FileCopyrightText: 2022 ivan tkachenko <me@ratijas.tk>
|
||||||
|
|
||||||
SPDX-License-Identifier: GPL-2.0-or-later
|
SPDX-License-Identifier: GPL-2.0-or-later
|
||||||
*/
|
*/
|
||||||
|
@ -57,6 +58,12 @@ WindowViewEffectConfig::WindowViewEffectConfig(QWidget *parent, const QVariantLi
|
||||||
KGlobalAccel::self()->setDefaultShortcut(toggleAction, {defaultToggleShortcutClass});
|
KGlobalAccel::self()->setDefaultShortcut(toggleAction, {defaultToggleShortcutClass});
|
||||||
KGlobalAccel::self()->setShortcut(toggleAction, {defaultToggleShortcutClass});
|
KGlobalAccel::self()->setShortcut(toggleAction, {defaultToggleShortcutClass});
|
||||||
|
|
||||||
|
toggleAction = actionCollection->addAction(QStringLiteral("ExposeClassCurrentDesktop"));
|
||||||
|
toggleAction->setText(i18n("Toggle Present Windows (Window class on current desktop)"));
|
||||||
|
toggleAction->setProperty("isConfigurationAction", true);
|
||||||
|
KGlobalAccel::self()->setDefaultShortcut(toggleAction, QList<QKeySequence>()); // no default shortcut
|
||||||
|
KGlobalAccel::self()->setShortcut(toggleAction, QList<QKeySequence>());
|
||||||
|
|
||||||
ui.shortcutsEditor->addCollection(actionCollection);
|
ui.shortcutsEditor->addCollection(actionCollection);
|
||||||
connect(ui.shortcutsEditor, &KShortcutsEditor::keyChange, this, &WindowViewEffectConfig::markAsChanged);
|
connect(ui.shortcutsEditor, &KShortcutsEditor::keyChange, this, &WindowViewEffectConfig::markAsChanged);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue