parent
bbc833baa6
commit
2505fd03f1
3 changed files with 42 additions and 0 deletions
@ -0,0 +1,33 @@ |
||||
/*
|
||||
SPDX-FileCopyrightText: 2023 Marco Martin <mart@kde.org> |
||||
|
||||
SPDX-License-Identifier: GPL-2.0-or-later |
||||
*/ |
||||
|
||||
#include <KGlobalAccel> |
||||
|
||||
#include <QAction> |
||||
#include <QGuiApplication> |
||||
#include <QStandardPaths> |
||||
|
||||
int main(int argc, char **argv) |
||||
{ |
||||
QGuiApplication app(argc, argv); |
||||
|
||||
const QStringList actionNames{ |
||||
QStringLiteral("Walk Through Desktops"), |
||||
QStringLiteral("Walk Through Desktops (Reverse)"), |
||||
QStringLiteral("Walk Through Desktop List"), |
||||
QStringLiteral("Walk Through Desktop List (Reverse)"), |
||||
}; |
||||
|
||||
for (const QString &actionName : actionNames) { |
||||
QAction action; |
||||
action.setObjectName(actionName); |
||||
action.setProperty("componentName", QStringLiteral("kwin")); |
||||
KGlobalAccel::self()->setShortcut(&action, {QKeySequence()}, KGlobalAccel::NoAutoloading); |
||||
KGlobalAccel::self()->removeAllShortcuts(&action); |
||||
} |
||||
|
||||
return 0; |
||||
} |
||||
Loading…
Reference in new issue