Add KGlobalAccel::setInverseShortcutActions() where appropriate

Depends on new API proposed for KGlobalAccel 6.26. This can help System Settings to suggest or require shortcuts for both actions of a forward/backward pair. Specifically also for gesture support once it arrives.

This also changes from KGlobalAccel::self()->setGlobalShortcut() to just KGlobalAccel::setGlobalShortcut() in these places, as this is a static function and resolves self() internally anyway.

This MR extracts the "easy part" of gesture support MR !9062, expanded to cover all inverse actions in KWin that I found in my kglobalshortcutsrc.

Note that I deliberately did not add the quick-tile up/down/left/right actions as inverse of each other, because e.g. quick-tile left followed by quick-tile right does not end up in the original state again.

Edited by Jakob Petsovits

Merge request reports

Loading