overview: no cursor warp for click-to-focus, add ws focus

This commit is contained in:
end-4
2025-04-24 10:01:26 +02:00
parent e612abad23
commit 700b126a9e
2 changed files with 18 additions and 4 deletions
@@ -5,6 +5,7 @@ import Qt5Compat.GraphicalEffects
import QtQuick
import QtQuick.Layouts
import Quickshell
import Quickshell.Io
import Quickshell.Widgets
import Quickshell.Wayland
import Quickshell.Hyprland
@@ -32,9 +33,10 @@ Item {
property Component windowComponent: OverviewWindow {}
property list<OverviewWindow> windowWidgets: []
// onWindowsChanged: {
// console.log("Windows changed")
// }
Process {
id: closeOverview
command: ["bash", "-c", "qs ipc call overview close &"] // Somehow has to by async to work?
}
Rectangle {
id: overviewBackground
@@ -69,6 +71,15 @@ Item {
color: Appearance.colors.colLayer1 // TODO: reconsider this color for a cleaner look
radius: Appearance.rounding.screenRounding * root.scale
MouseArea {
id: mouseArea
anchors.fill: parent
onClicked: (event) => {
closeOverview.running = true
Hyprland.dispatch(`workspace ${workspace.workspaceValue}`)
}
}
StyledText {
z: 9999
anchors.left: parent.left