diff --git a/Services/CompositorService.qml b/Services/CompositorService.qml index b5cd62d2..4d30421c 100644 --- a/Services/CompositorService.qml +++ b/Services/CompositorService.qml @@ -128,7 +128,15 @@ Singleton { windowListChanged() } - // Get window title for focused window + // Get focused window + function getFocusedWindow() { + if (focusedWindowIndex >= 0 && focusedWindowIndex < windows.count) { + return windows.get(focusedWindowIndex) + } + return null + } + + // Get focused window title function getFocusedWindowTitle() { if (focusedWindowIndex >= 0 && focusedWindowIndex < windows.count) { return windows.get(focusedWindowIndex).title || "" @@ -177,14 +185,6 @@ Singleton { } } - // Get focused window - function getFocusedWindow() { - if (focusedWindowIndex >= 0 && focusedWindowIndex < windows.count) { - return windows[focusedWindowIndex] - } - return null - } - // Close window function closeWindow(windowId) { if (backend && backend.closeWindow) {