mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-01-29 16:02:51 -05:00
Add systemd-inhibit widget
This commit is contained in:
@@ -312,6 +312,8 @@ PanelWindow {
|
||||
return true
|
||||
case "controlCenterButton":
|
||||
return true
|
||||
case "idleInhibitor":
|
||||
return true
|
||||
case "spacer":
|
||||
return true
|
||||
case "separator":
|
||||
@@ -355,6 +357,8 @@ PanelWindow {
|
||||
return batteryComponent
|
||||
case "controlCenterButton":
|
||||
return controlCenterButtonComponent
|
||||
case "idleInhibitor":
|
||||
return idleInhibitorComponent
|
||||
case "spacer":
|
||||
return spacerComponent
|
||||
case "separator":
|
||||
@@ -953,6 +957,23 @@ PanelWindow {
|
||||
}
|
||||
}
|
||||
|
||||
Component {
|
||||
id: idleInhibitorComponent
|
||||
|
||||
IdleInhibitor {
|
||||
section: {
|
||||
if (parent && parent.parent === leftSection)
|
||||
return "left"
|
||||
if (parent && parent.parent === rightSection)
|
||||
return "right"
|
||||
if (parent && parent.parent === centerSection)
|
||||
return "center"
|
||||
return "right"
|
||||
}
|
||||
parentScreen: root.screen
|
||||
}
|
||||
}
|
||||
|
||||
Component {
|
||||
id: spacerComponent
|
||||
|
||||
|
||||
Reference in New Issue
Block a user