mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-27 06:33:08 +00:00
Personnaly, I don't like much those static icons which doesn't care about the situation in the quicksettings. This MR intends to use when possible and coherent what I call (not native English-speaking I recall) « adaptive » icon. List of modified quicksettings : - Wireless - Bluetooth - Flashlight - Audio - Airplane mode ~~Draft right now because I'm doing it quicksetting-by-quicksetting.~~ EDIT: Feel free to cherry-pick if you don't agree with all icons.
25 lines
807 B
QML
25 lines
807 B
QML
/*
|
|
* SPDX-FileCopyrightText: 2021 Bhushan Shah <bshah@kde.org>
|
|
* SPDX-FileCopyrightText: 2021 Nicolas Fella <nicolas.fella@gmx.de>
|
|
*
|
|
* SPDX-License-Identifier: LGPL-2.0-or-later
|
|
*/
|
|
|
|
import org.kde.plasma.networkmanagement as PlasmaNM
|
|
import org.kde.plasma.private.mobileshell.quicksettingsplugin as QS
|
|
|
|
QS.QuickSetting {
|
|
text: i18n("Airplane Mode")
|
|
icon: PlasmaNM.Configuration.airplaneModeEnabled ? "network-flightmode-on" : "network-flightmode-off"
|
|
status: ""
|
|
enabled: PlasmaNM.Configuration.airplaneModeEnabled
|
|
|
|
PlasmaNM.Handler {
|
|
id: nmHandler
|
|
}
|
|
|
|
function toggle() {
|
|
nmHandler.enableAirplaneMode(!PlasmaNM.Configuration.airplaneModeEnabled);
|
|
PlasmaNM.Configuration.airplaneModeEnabled = !PlasmaNM.Configuration.airplaneModeEnabled;
|
|
}
|
|
}
|