plugins/overview: Revoke Meta+Tab and Meta+Shift+Tab shortcuts
These shortcuts make more sense to be used with Meta+Tab and Meta+Shift+Tab. Let's keep them reserved for the task switcher. Cycling between overview modes is not something that requires Meta+Tab to be assigned to it by default.
This commit is contained in:
parent
540dff30e7
commit
cd43199e70
2 changed files with 8 additions and 12 deletions
|
@ -36,19 +36,17 @@ OverviewEffectConfig::OverviewEffectConfig(QObject *parent, const KPluginMetaDat
|
|||
actionCollection->setConfigGroup(QStringLiteral("Overview"));
|
||||
actionCollection->setConfigGlobal(true);
|
||||
|
||||
const QKeySequence defaultCycleShortcut = Qt::META | Qt::Key_Tab;
|
||||
QAction *cycleAction = actionCollection->addAction(QStringLiteral("Cycle Overview"));
|
||||
cycleAction->setText(i18nc("@action Overview and Grid View are the name of KWin effects", "Cycle through Overview and Grid View"));
|
||||
cycleAction->setProperty("isConfigurationAction", true);
|
||||
KGlobalAccel::self()->setDefaultShortcut(cycleAction, {defaultCycleShortcut});
|
||||
KGlobalAccel::self()->setShortcut(cycleAction, {defaultCycleShortcut});
|
||||
KGlobalAccel::self()->setDefaultShortcut(cycleAction, {});
|
||||
KGlobalAccel::self()->setShortcut(cycleAction, {});
|
||||
|
||||
const QKeySequence defaultUncycleShortcut = Qt::META | Qt::SHIFT | Qt::Key_Tab;
|
||||
QAction *reverseCycleAction = actionCollection->addAction(QStringLiteral("Cycle Overview Opposite"));
|
||||
reverseCycleAction->setText(i18nc("@action Grid View and Overview are the name of KWin effects", "Cycle through Grid View and Overview"));
|
||||
reverseCycleAction->setProperty("isConfigurationAction", true);
|
||||
KGlobalAccel::self()->setDefaultShortcut(reverseCycleAction, {defaultUncycleShortcut});
|
||||
KGlobalAccel::self()->setShortcut(reverseCycleAction, {defaultUncycleShortcut});
|
||||
KGlobalAccel::self()->setDefaultShortcut(reverseCycleAction, {});
|
||||
KGlobalAccel::self()->setShortcut(reverseCycleAction, {});
|
||||
|
||||
const QKeySequence defaultOverviewShortcut = Qt::META | Qt::Key_W;
|
||||
QAction *overviewAction = actionCollection->addAction(QStringLiteral("Overview"));
|
||||
|
|
|
@ -118,22 +118,20 @@ OverviewEffect::OverviewEffect()
|
|||
m_shutdownTimer->setSingleShot(true);
|
||||
connect(m_shutdownTimer, &QTimer::timeout, this, &OverviewEffect::realDeactivate);
|
||||
|
||||
const QKeySequence defaultCycleShortcut = Qt::META | Qt::Key_Tab;
|
||||
auto cycleAction = new QAction(this);
|
||||
connect(cycleAction, &QAction::triggered, this, &OverviewEffect::cycle);
|
||||
cycleAction->setObjectName(QStringLiteral("Cycle Overview"));
|
||||
cycleAction->setText(i18nc("@action Grid View and Overview are the name of KWin effects", "Cycle through Overview and Grid View"));
|
||||
KGlobalAccel::self()->setDefaultShortcut(cycleAction, {defaultCycleShortcut});
|
||||
KGlobalAccel::self()->setShortcut(cycleAction, {defaultCycleShortcut});
|
||||
KGlobalAccel::self()->setDefaultShortcut(cycleAction, {});
|
||||
KGlobalAccel::self()->setShortcut(cycleAction, {});
|
||||
m_cycleShortcut = KGlobalAccel::self()->shortcut(cycleAction);
|
||||
|
||||
const QKeySequence defaultUncycleShortcut = Qt::META | Qt::SHIFT | Qt::Key_Tab;
|
||||
auto reverseCycleAction = new QAction(this);
|
||||
connect(reverseCycleAction, &QAction::triggered, this, &OverviewEffect::reverseCycle);
|
||||
reverseCycleAction->setObjectName(QStringLiteral("Cycle Overview Opposite"));
|
||||
reverseCycleAction->setText(i18nc("@action Grid View and Overview are the name of KWin effects", "Cycle through Grid View and Overview"));
|
||||
KGlobalAccel::self()->setDefaultShortcut(reverseCycleAction, {defaultUncycleShortcut});
|
||||
KGlobalAccel::self()->setShortcut(reverseCycleAction, {defaultUncycleShortcut});
|
||||
KGlobalAccel::self()->setDefaultShortcut(reverseCycleAction, {});
|
||||
KGlobalAccel::self()->setShortcut(reverseCycleAction, {});
|
||||
m_reverseCycleShortcut = KGlobalAccel::self()->shortcut(reverseCycleAction);
|
||||
|
||||
const QKeySequence defaultOverviewShortcut = Qt::META | Qt::Key_W;
|
||||
|
|
Loading…
Reference in a new issue