Revert "Make overview and present windows use realtime gestures"

This reverts commit 6729380c54.

It didn't go through code review process.
This commit is contained in:
Vlad Zahorodnii 2022-03-19 18:29:26 +02:00
parent 6729380c54
commit 7e14716043
2 changed files with 2 additions and 17 deletions

View file

@ -39,14 +39,7 @@ OverviewEffect::OverviewEffect()
KGlobalAccel::self()->setShortcut(m_toggleAction, {defaultToggleShortcut}); KGlobalAccel::self()->setShortcut(m_toggleAction, {defaultToggleShortcut});
m_toggleShortcut = KGlobalAccel::self()->shortcut(m_toggleAction); m_toggleShortcut = KGlobalAccel::self()->shortcut(m_toggleAction);
effects->registerGlobalShortcut({defaultToggleShortcut}, m_toggleAction); effects->registerGlobalShortcut({defaultToggleShortcut}, m_toggleAction);
effects->registerRealtimeTouchpadSwipeShortcut(SwipeDirection::Up, 4, new QAction(), [this](qreal cb) { //m_toggleAction effects->registerTouchpadSwipeShortcut(SwipeDirection::Up, 4, m_toggleAction);
if (cb > .2 && !isRunning()) {
activate();
}
if (cb <= .2 && isRunning()) {
deactivate();
}
});
connect(effects, &EffectsHandler::screenAboutToLock, this, &OverviewEffect::realDeactivate); connect(effects, &EffectsHandler::screenAboutToLock, this, &OverviewEffect::realDeactivate);

View file

@ -82,15 +82,7 @@ PresentWindowsEffect::PresentWindowsEffect()
KGlobalAccel::self()->setShortcut(exposeAllAction, QList<QKeySequence>() << (Qt::CTRL | Qt::Key_F10) << Qt::Key_LaunchC); KGlobalAccel::self()->setShortcut(exposeAllAction, QList<QKeySequence>() << (Qt::CTRL | Qt::Key_F10) << Qt::Key_LaunchC);
shortcutAll = KGlobalAccel::self()->shortcut(exposeAllAction); shortcutAll = KGlobalAccel::self()->shortcut(exposeAllAction);
effects->registerGlobalShortcut(Qt::CTRL + Qt::Key_F10, exposeAllAction); effects->registerGlobalShortcut(Qt::CTRL + Qt::Key_F10, exposeAllAction);
effects->registerRealtimeTouchpadSwipeShortcut(SwipeDirection::Down, 4, new QAction(), [this](qreal cb) { //exposeAllAction effects->registerTouchpadSwipeShortcut(SwipeDirection::Down, 4, exposeAllAction);
m_mode = ModeAllDesktops;
if (cb > .2 && !m_activated) {
setActive(true);
}
if (cb < .2 && m_activated) {
setActive(false);
}
});
connect(exposeAllAction, &QAction::triggered, this, &PresentWindowsEffect::toggleActiveAllDesktops); connect(exposeAllAction, &QAction::triggered, this, &PresentWindowsEffect::toggleActiveAllDesktops);
QAction* exposeClassAction = m_exposeClassAction; QAction* exposeClassAction = m_exposeClassAction;