potential fix for gesture-only mode not working

call reconfigure in mobiletaskswitcher constructor to make it set the touch border.
this fixes the gesture-only mode in my setup, though one oddity remains: it only starts working after using the action drawer once - that may be an issue with my dev setup though.
This commit is contained in:
Luis Büchi 2024-02-19 04:03:58 +00:00 committed by Devin Lin
parent 6456a58eba
commit 646be07c6c
3 changed files with 14 additions and 15 deletions

View file

@ -91,8 +91,7 @@ void MobileShellSettings::setNavigationPanelEnabled(bool navigationPanelEnabled)
group.writeEntry("navigationPanelEnabled", navigationPanelEnabled, KConfigGroup::Notify); group.writeEntry("navigationPanelEnabled", navigationPanelEnabled, KConfigGroup::Notify);
m_config->sync(); m_config->sync();
// TODO: Gesture only mode setting is disabled until we get the kwin effect gesture working: https://invent.kde.org/plasma/plasma-mobile/-/issues/300 updateNavigationBarsInPlasma(navigationPanelEnabled);
// updateNavigationBarsInPlasma(navigationPanelEnabled);
} }
bool MobileShellSettings::alwaysShowKeyboardToggleOnNavigationPanel() const bool MobileShellSettings::alwaysShowKeyboardToggleOnNavigationPanel() const

View file

@ -54,20 +54,19 @@ KCM.SimpleKCM {
} }
FormCard.FormCard { FormCard.FormCard {
// TODO: Gesture only mode setting is disabled until we get the kwin effect gesture working: https://invent.kde.org/plasma/plasma-mobile/-/issues/300 FormCard.FormSwitchDelegate {
// FormCard.FormSwitchDelegate { id: gestureDelegate
// id: gestureDelegate text: i18n("Gesture-only Mode")
// text: i18n("Gesture-only Mode") description: i18n("Whether to hide the navigation panel.")
// description: i18n("Whether to hide the navigation panel.") checked: !ShellSettings.Settings.navigationPanelEnabled
// checked: !ShellSettings.Settings.navigationPanelEnabled onCheckedChanged: {
// onCheckedChanged: { if (checked != !ShellSettings.Settings.navigationPanelEnabled) {
// if (checked != !ShellSettings.Settings.navigationPanelEnabled) { ShellSettings.Settings.navigationPanelEnabled = !checked;
// ShellSettings.Settings.navigationPanelEnabled = !checked; }
// } }
// } }
// }
// FormCard.FormDelegateSeparator { visible: keyboardToggleDelegate.visible; above: gestureDelegate; below: keyboardToggleDelegate } FormCard.FormDelegateSeparator { visible: keyboardToggleDelegate.visible; above: gestureDelegate; below: keyboardToggleDelegate }
FormCard.FormSwitchDelegate { FormCard.FormSwitchDelegate {
id: keyboardToggleDelegate id: keyboardToggleDelegate

View file

@ -51,6 +51,7 @@ MobileTaskSwitcherEffect::MobileTaskSwitcherEffect()
setSource(QUrl::fromLocalFile( setSource(QUrl::fromLocalFile(
QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("kwin/effects/mobiletaskswitcher/qml/TaskSwitcher.qml")))); QStandardPaths::locate(QStandardPaths::GenericDataLocation, QStringLiteral("kwin/effects/mobiletaskswitcher/qml/TaskSwitcher.qml"))));
reconfigure(ReconfigureFlag::ReconfigureAll);
} }
MobileTaskSwitcherEffect::~MobileTaskSwitcherEffect() MobileTaskSwitcherEffect::~MobileTaskSwitcherEffect()