mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-06-11 16:57:43 +00:00
Expose dynamicTilingEnabled (default true) on MobileShellSettings, stored under the General group of plasmamobilerc and re-emitted by the existing config watcher. shift-tiling extends its activation guard with this flag and clears the BSP layout when it goes false, so users can fall back to KWin native quick-tile at will. Add a quick-settings tile that surfaces the toggle. available is gated on convergenceModeEnabled and !gamingModeEnabled, so the tile is hidden on the phone form factor and during gaming sessions.
23 lines
778 B
QML
23 lines
778 B
QML
// SPDX-FileCopyrightText: 2026 Marco Allegretti
|
|
// SPDX-License-Identifier: LGPL-2.0-or-later
|
|
|
|
import QtQuick
|
|
|
|
import org.kde.plasma.private.mobileshell.shellsettingsplugin as ShellSettings
|
|
import org.kde.plasma.private.mobileshell.quicksettingsplugin as QS
|
|
|
|
QS.QuickSetting {
|
|
text: i18n("Dynamic Tiling")
|
|
icon: "view-grid-symbolic"
|
|
|
|
// Only meaningful in convergence (desktop) mode. Hidden everywhere else.
|
|
available: ShellSettings.Settings.convergenceModeEnabled
|
|
&& !ShellSettings.Settings.gamingModeEnabled
|
|
|
|
enabled: ShellSettings.Settings.dynamicTilingEnabled
|
|
status: enabled ? i18n("On") : i18n("Off")
|
|
|
|
function toggle() {
|
|
ShellSettings.Settings.dynamicTilingEnabled = !ShellSettings.Settings.dynamicTilingEnabled;
|
|
}
|
|
}
|