mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-08-03 02:04:45 +00:00
Move the Volume quick setting with its provider
So not to rely on global identifiers
This commit is contained in:
parent
3b212d7a55
commit
0d7f10abbc
2 changed files with 11 additions and 9 deletions
|
|
@ -147,6 +147,17 @@ Item {
|
||||||
}
|
}
|
||||||
IndicatorProviders.VolumeProvider {
|
IndicatorProviders.VolumeProvider {
|
||||||
id: volumeProvider
|
id: volumeProvider
|
||||||
|
|
||||||
|
readonly property var soundQuickSetting: QuickSetting {
|
||||||
|
text: i18n("Sound")
|
||||||
|
icon: "audio-speakers-symbolic"
|
||||||
|
enabled: false
|
||||||
|
settingsCommand: "plasma-settings -m kcm_pulseaudio"
|
||||||
|
function toggle() {
|
||||||
|
volumeProvider.showVolumeOverlay()
|
||||||
|
}
|
||||||
|
Component.onCompleted: quickSettings.quickSettingsModel.model.push(volumeProvider.soundQuickSetting)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
IndicatorProviders.WifiProvider {
|
IndicatorProviders.WifiProvider {
|
||||||
id: wifiProvider
|
id: wifiProvider
|
||||||
|
|
|
||||||
|
|
@ -76,15 +76,6 @@ Item {
|
||||||
enabled: false
|
enabled: false
|
||||||
settingsCommand: "plasma-settings -m kcm_mobile_power"
|
settingsCommand: "plasma-settings -m kcm_mobile_power"
|
||||||
},
|
},
|
||||||
QuickSetting {
|
|
||||||
text: i18n("Sound")
|
|
||||||
icon: "audio-speakers-symbolic"
|
|
||||||
enabled: false
|
|
||||||
settingsCommand: "plasma-settings -m kcm_pulseaudio"
|
|
||||||
function toggle() {
|
|
||||||
volumeProvider.showVolumeOverlay()
|
|
||||||
}
|
|
||||||
},
|
|
||||||
QuickSetting {
|
QuickSetting {
|
||||||
text: i18n("Flashlight")
|
text: i18n("Flashlight")
|
||||||
icon: "flashlight-on"
|
icon: "flashlight-on"
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue