WIP per-monitor workspaces - Hyprland
This commit is contained in:
@@ -47,6 +47,7 @@ Scope {
|
|||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.topMargin: 6
|
Layout.topMargin: 6
|
||||||
Layout.bottomMargin: 6
|
Layout.bottomMargin: 6
|
||||||
|
screen: bar.screen
|
||||||
}
|
}
|
||||||
|
|
||||||
AudioWidget {
|
AudioWidget {
|
||||||
|
|||||||
@@ -7,7 +7,7 @@ import qs.Modules
|
|||||||
|
|
||||||
PopupWindow {
|
PopupWindow {
|
||||||
id: popup
|
id: popup
|
||||||
color: "#FF202020"
|
color: "#00202020"
|
||||||
|
|
||||||
required property QsMenuOpener trayMenu
|
required property QsMenuOpener trayMenu
|
||||||
|
|
||||||
|
|||||||
@@ -18,7 +18,8 @@ Item {
|
|||||||
running: false
|
running: false
|
||||||
stdout: StdioCollector {
|
stdout: StdioCollector {
|
||||||
onStreamFinished: {
|
onStreamFinished: {
|
||||||
root.currentTitle = this.text.trim().replace(/\"/g, "")
|
let cleaned = this.text.trim().replace(/\"/g, "")
|
||||||
|
root.currentTitle = ( cleaned === "null" ) ? "" : cleaned
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,6 +7,20 @@ import Quickshell.Hyprland
|
|||||||
Rectangle {
|
Rectangle {
|
||||||
id: root
|
id: root
|
||||||
|
|
||||||
|
required property ShellScreen screen
|
||||||
|
|
||||||
|
readonly property int activeWsId: ( Hyprland.monitorFor( screen ).activeWorkspace?.id ?? 1 )
|
||||||
|
|
||||||
|
readonly property var occupied: Hyprland.workspaces.values.reduce(( acc, curr ) => {
|
||||||
|
acc[ curr.id ] = curr.lastIpcObject.windows > 0;
|
||||||
|
return acc;
|
||||||
|
})
|
||||||
|
readonly property int groupOffset: Math.floor(( activeWsId - 1 ) / 10) * 10
|
||||||
|
readonly property int ws: 1 + groupOffset
|
||||||
|
|
||||||
|
readonly property bool isOccupied: occupied[ ws ] ?? false
|
||||||
|
|
||||||
|
|
||||||
implicitWidth: workspacesRow.implicitWidth + 10
|
implicitWidth: workspacesRow.implicitWidth + 10
|
||||||
implicitHeight: workspacesRow.implicitHeight + 7
|
implicitHeight: workspacesRow.implicitHeight + 7
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user