bar: some workspaces optimisations
This commit is contained in:
parent
e8fe4ef673
commit
96c8226def
1 changed files with 2 additions and 3 deletions
|
|
@ -14,10 +14,9 @@ Rectangle {
|
|||
required property real maskHeight
|
||||
required property int groupOffset
|
||||
|
||||
property int currentIdx: (Hyprland.activeWorkspace?.id ?? 1) - 1 - groupOffset
|
||||
property int lastIdx: currentIdx
|
||||
property int currentIdx: Hyprland.activeWsId - 1 - groupOffset
|
||||
property real leading: workspaces[currentIdx][vertical ? "y" : "x"]
|
||||
property real trailing: workspaces[lastIdx][vertical ? "y" : "x"]
|
||||
property real trailing: workspaces[currentIdx][vertical ? "y" : "x"]
|
||||
property real currentSize: workspaces[currentIdx][vertical ? "height" : "width"]
|
||||
property real size: Math.abs(leading - trailing) + currentSize
|
||||
property real offset: Math.min(leading, trailing)
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue