diff options
| author | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-06-27 21:37:15 +1000 |
|---|---|---|
| committer | 2 * r + 2 * t <61896496+soramanew@users.noreply.github.com> | 2025-06-27 21:37:15 +1000 |
| commit | b264ae9888575df22e15d89a361845f84202106a (patch) | |
| tree | 4b3d85117265f35b2ddda0fd00e3643b3b16d27c /modules/windowinfo/Preview.qml | |
| parent | icons: fix grade more icons (diff) | |
| download | caelestia-shell-b264ae9888575df22e15d89a361845f84202106a.tar.gz caelestia-shell-b264ae9888575df22e15d89a361845f84202106a.tar.bz2 caelestia-shell-b264ae9888575df22e15d89a361845f84202106a.zip | |
internal: use hyprlandtoplevel
Diffstat (limited to 'modules/windowinfo/Preview.qml')
| -rw-r--r-- | modules/windowinfo/Preview.qml | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/modules/windowinfo/Preview.qml b/modules/windowinfo/Preview.qml index 96542c4..2619e8a 100644 --- a/modules/windowinfo/Preview.qml +++ b/modules/windowinfo/Preview.qml @@ -34,7 +34,7 @@ Item { Loader { anchors.centerIn: parent - active: !Hyprland.activeClient + active: !Hyprland.activeToplevel asynchronous: true sourceComponent: ColumnLayout { @@ -69,10 +69,10 @@ Item { anchors.centerIn: parent - captureSource: Hyprland.activeClient ? ToplevelManager.activeToplevel : null + captureSource: Hyprland.activeToplevel?.wayland ?? null live: true - constraintSize.width: parent.height * Math.min(screen.width / screen.height, Hyprland.activeClient.width / Hyprland.activeClient.height) + constraintSize.width: parent.height * Math.min(root.screen.width / root.screen.height, Hyprland.activeToplevel?.lastIpcObject.size[0] / Hyprland.activeToplevel?.lastIpcObject.size[1]) constraintSize.height: parent.height } } @@ -86,11 +86,11 @@ Item { animate: true text: { - const client = Hyprland.activeClient; + const client = Hyprland.activeToplevel; if (!client) return qsTr("No active client"); - const mon = Hyprland.monitors.values[Hyprland.activeClient.lastIpcObject.monitor]; + const mon = client.monitor; return qsTr("%1 on monitor %2 at %3, %4").arg(client.title).arg(mon.name).arg(client.x).arg(client.y); } } |