diff --git a/Modals/Clipboard/ClipboardHistoryModal.qml b/Modals/Clipboard/ClipboardHistoryModal.qml index 07844cc1..d6477ea7 100644 --- a/Modals/Clipboard/ClipboardHistoryModal.qml +++ b/Modals/Clipboard/ClipboardHistoryModal.qml @@ -188,17 +188,17 @@ DankModal { } IpcHandler { - function open() { + function open(): string { clipboardHistoryModal.show() return "CLIPBOARD_OPEN_SUCCESS" } - function close() { - hide() + function close(): string { + clipboardHistoryModal.hide() return "CLIPBOARD_CLOSE_SUCCESS" } - function toggle() { + function toggle(): string { clipboardHistoryModal.toggle() return "CLIPBOARD_TOGGLE_SUCCESS" } diff --git a/Modals/NotificationModal.qml b/Modals/NotificationModal.qml index dc0a2ced..cf381fb4 100644 --- a/Modals/NotificationModal.qml +++ b/Modals/NotificationModal.qml @@ -60,17 +60,17 @@ DankModal { } IpcHandler { - function open() { + function open(): string { notificationModal.show(); return "NOTIFICATION_MODAL_OPEN_SUCCESS"; } - function close() { + function close(): string { notificationModal.hide(); return "NOTIFICATION_MODAL_CLOSE_SUCCESS"; } - function toggle() { + function toggle(): string { notificationModal.toggle(); return "NOTIFICATION_MODAL_TOGGLE_SUCCESS"; } diff --git a/Modals/Settings/SettingsModal.qml b/Modals/Settings/SettingsModal.qml index 40412c58..80300825 100644 --- a/Modals/Settings/SettingsModal.qml +++ b/Modals/Settings/SettingsModal.qml @@ -41,17 +41,17 @@ DankModal { content: settingsContent IpcHandler { - function open() { + function open(): string { settingsModal.show(); return "SETTINGS_OPEN_SUCCESS"; } - function close() { + function close(): string { settingsModal.hide(); return "SETTINGS_CLOSE_SUCCESS"; } - function toggle() { + function toggle(): string { settingsModal.toggle(); return "SETTINGS_TOGGLE_SUCCESS"; } diff --git a/Modals/Spotlight/SpotlightModal.qml b/Modals/Spotlight/SpotlightModal.qml index 709d865a..764a7717 100644 --- a/Modals/Spotlight/SpotlightModal.qml +++ b/Modals/Spotlight/SpotlightModal.qml @@ -83,17 +83,17 @@ DankModal { } IpcHandler { - function open() { + function open(): string { spotlightModal.show() return "SPOTLIGHT_OPEN_SUCCESS" } - function close() { + function close(): string { spotlightModal.hide() return "SPOTLIGHT_CLOSE_SUCCESS" } - function toggle() { + function toggle(): string { spotlightModal.toggle() return "SPOTLIGHT_TOGGLE_SUCCESS" } diff --git a/Modules/Lock/Lock.qml b/Modules/Lock/Lock.qml index 1f2f914e..0d1e0047 100644 --- a/Modules/Lock/Lock.qml +++ b/Modules/Lock/Lock.qml @@ -135,13 +135,13 @@ Item { IpcHandler { target: "lock" - function lock(): void { + function lock() { console.log("Lock screen requested via IPC") LockScreenService.resetState() loader.activeAsync = true } - function demo(): void { + function demo() { console.log("Lock screen DEMO mode requested via IPC") demoWindow.showDemo() } diff --git a/shell.qml b/shell.qml index 91d78708..aa1e2b8c 100644 --- a/shell.qml +++ b/shell.qml @@ -338,7 +338,7 @@ ShellRoot { } IpcHandler { - function open() { + function open(): string { processListModalLoader.active = true if (processListModalLoader.item) processListModalLoader.item.show() @@ -346,14 +346,14 @@ ShellRoot { return "PROCESSLIST_OPEN_SUCCESS" } - function close() { + function close(): string { if (processListModalLoader.item) processListModalLoader.item.hide() return "PROCESSLIST_CLOSE_SUCCESS" } - function toggle() { + function toggle(): string { processListModalLoader.active = true if (processListModalLoader.item) processListModalLoader.item.toggle() @@ -365,7 +365,7 @@ ShellRoot { } IpcHandler { - function open() { + function open(): string { notepadSlideoutLoader.active = true if (notepadSlideoutLoader.item) { notepadSlideoutLoader.item.show() @@ -374,7 +374,7 @@ ShellRoot { return "NOTEPAD_OPEN_FAILED" } - function close() { + function close(): string { if (notepadSlideoutLoader.item) { notepadSlideoutLoader.item.hide() return "NOTEPAD_CLOSE_SUCCESS" @@ -382,7 +382,7 @@ ShellRoot { return "NOTEPAD_CLOSE_FAILED" } - function toggle() { + function toggle(): string { notepadSlideoutLoader.active = true if (notepadSlideoutLoader.item) { notepadSlideoutLoader.item.toggle()