internal: use execDetached
This commit is contained in:
parent
2dbec4489e
commit
f14d00d3dc
3 changed files with 7 additions and 42 deletions
|
|
@ -75,7 +75,7 @@ Singleton {
|
|||
|
||||
function onClicked(list: AppList): void {
|
||||
list.visibilities.launcher = false;
|
||||
shutdown.running = true;
|
||||
Quickshell.execDetached(["systemctl", "poweroff"]);
|
||||
}
|
||||
},
|
||||
Action {
|
||||
|
|
@ -86,7 +86,7 @@ Singleton {
|
|||
|
||||
function onClicked(list: AppList): void {
|
||||
list.visibilities.launcher = false;
|
||||
reboot.running = true;
|
||||
Quickshell.execDetached(["systemctl", "reboot"]);
|
||||
}
|
||||
},
|
||||
Action {
|
||||
|
|
@ -97,7 +97,7 @@ Singleton {
|
|||
|
||||
function onClicked(list: AppList): void {
|
||||
list.visibilities.launcher = false;
|
||||
logout.running = true;
|
||||
Quickshell.execDetached(["sh", "-c", "(uwsm stop | grep -q 'Compositor is not running' && loginctl terminate-user $USER) || uwsm stop"]);
|
||||
}
|
||||
},
|
||||
Action {
|
||||
|
|
@ -107,7 +107,7 @@ Singleton {
|
|||
|
||||
function onClicked(list: AppList): void {
|
||||
list.visibilities.launcher = false;
|
||||
lock.running = true;
|
||||
Quickshell.execDetached(["loginctl", "lock-session"]);
|
||||
}
|
||||
},
|
||||
Action {
|
||||
|
|
@ -117,7 +117,7 @@ Singleton {
|
|||
|
||||
function onClicked(list: AppList): void {
|
||||
list.visibilities.launcher = false;
|
||||
sleep.running = true;
|
||||
Quickshell.execDetached(["systemctl", "suspend-then-hibernate"]);
|
||||
}
|
||||
}
|
||||
]
|
||||
|
|
@ -140,36 +140,6 @@ Singleton {
|
|||
list.search.text = `${Config.launcher.actionPrefix}${text} `;
|
||||
}
|
||||
|
||||
Process {
|
||||
id: shutdown
|
||||
|
||||
command: ["systemctl", "poweroff"]
|
||||
}
|
||||
|
||||
Process {
|
||||
id: reboot
|
||||
|
||||
command: ["systemctl", "reboot"]
|
||||
}
|
||||
|
||||
Process {
|
||||
id: logout
|
||||
|
||||
command: ["sh", "-c", "(uwsm stop | grep -q 'Compositor is not running' && loginctl terminate-user $USER) || uwsm stop"]
|
||||
}
|
||||
|
||||
Process {
|
||||
id: lock
|
||||
|
||||
command: ["loginctl", "lock-session"]
|
||||
}
|
||||
|
||||
Process {
|
||||
id: sleep
|
||||
|
||||
command: ["systemctl", "suspend-then-hibernate"]
|
||||
}
|
||||
|
||||
component Action: QtObject {
|
||||
required property string name
|
||||
required property string desc
|
||||
|
|
|
|||
|
|
@ -60,8 +60,8 @@ Singleton {
|
|||
readonly property var colours: modelData.colours
|
||||
|
||||
function onClicked(list: AppList): void {
|
||||
Quickshell.execDetached(["caelestia", "scheme", "set", "-n", name, "-f", flavour]);
|
||||
list.visibilities.launcher = false;
|
||||
Quickshell.execDetached(["caelestia", "scheme", "set", "-n", name, "-f", flavour]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -53,12 +53,7 @@ Singleton {
|
|||
}
|
||||
|
||||
function setMode(mode: string): void {
|
||||
setModeProc.command = ["caelestia", "scheme", "set", "--notify", "-m", mode];
|
||||
setModeProc.startDetached();
|
||||
}
|
||||
|
||||
Process {
|
||||
id: setModeProc
|
||||
Quickshell.execDetached(["caelestia", "scheme", "set", "--notify", "-m", mode]);
|
||||
}
|
||||
|
||||
FileView {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue