mirror of
https://github.com/AvengeMedia/DankMaterialShell.git
synced 2026-08-07 14:08:29 -04:00
fix(process-list): defer IPC actions until modal is loaded (#2829)
Port 1.5
This commit is contained in:
@@ -179,8 +179,10 @@ Item {
|
|||||||
IpcHandler {
|
IpcHandler {
|
||||||
function open(): string {
|
function open(): string {
|
||||||
root.processListModalLoader.active = true;
|
root.processListModalLoader.active = true;
|
||||||
|
Qt.callLater(() => {
|
||||||
if (root.processListModalLoader.item)
|
if (root.processListModalLoader.item)
|
||||||
root.processListModalLoader.item.show();
|
root.processListModalLoader.item.show();
|
||||||
|
});
|
||||||
|
|
||||||
return "PROCESSLIST_OPEN_SUCCESS";
|
return "PROCESSLIST_OPEN_SUCCESS";
|
||||||
}
|
}
|
||||||
@@ -194,16 +196,20 @@ Item {
|
|||||||
|
|
||||||
function toggle(): string {
|
function toggle(): string {
|
||||||
root.processListModalLoader.active = true;
|
root.processListModalLoader.active = true;
|
||||||
|
Qt.callLater(() => {
|
||||||
if (root.processListModalLoader.item)
|
if (root.processListModalLoader.item)
|
||||||
root.processListModalLoader.item.toggle();
|
root.processListModalLoader.item.toggle();
|
||||||
|
});
|
||||||
|
|
||||||
return "PROCESSLIST_TOGGLE_SUCCESS";
|
return "PROCESSLIST_TOGGLE_SUCCESS";
|
||||||
}
|
}
|
||||||
|
|
||||||
function focusOrToggle(): string {
|
function focusOrToggle(): string {
|
||||||
root.processListModalLoader.active = true;
|
root.processListModalLoader.active = true;
|
||||||
|
Qt.callLater(() => {
|
||||||
if (root.processListModalLoader.item)
|
if (root.processListModalLoader.item)
|
||||||
root.processListModalLoader.item.focusOrToggle();
|
root.processListModalLoader.item.focusOrToggle();
|
||||||
|
});
|
||||||
|
|
||||||
return "PROCESSLIST_FOCUS_OR_TOGGLE_SUCCESS";
|
return "PROCESSLIST_FOCUS_OR_TOGGLE_SUCCESS";
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user