summaryrefslogtreecommitdiff
path: root/modules/bar/components
diff options
context:
space:
mode:
Diffstat (limited to 'modules/bar/components')
-rw-r--r--modules/bar/components/ActiveWindow.qml4
-rw-r--r--modules/bar/components/StatusIcons.qml2
-rw-r--r--modules/bar/components/workspaces/SpecialWorkspaces.qml12
-rw-r--r--modules/bar/components/workspaces/Workspace.qml2
-rw-r--r--modules/bar/components/workspaces/Workspaces.qml12
5 files changed, 16 insertions, 16 deletions
diff --git a/modules/bar/components/ActiveWindow.qml b/modules/bar/components/ActiveWindow.qml
index 3bea956..3b897c0 100644
--- a/modules/bar/components/ActiveWindow.qml
+++ b/modules/bar/components/ActiveWindow.qml
@@ -31,7 +31,7 @@ Item {
anchors.horizontalCenter: parent.horizontalCenter
animate: true
- text: Icons.getAppCategoryIcon(Hyprland.activeToplevel?.lastIpcObject.class, "desktop_windows")
+ text: Icons.getAppCategoryIcon(Hypr.activeToplevel?.lastIpcObject.class, "desktop_windows")
color: root.colour
}
@@ -46,7 +46,7 @@ Item {
TextMetrics {
id: metrics
- text: Hyprland.activeToplevel?.title ?? qsTr("Desktop")
+ text: Hypr.activeToplevel?.title ?? qsTr("Desktop")
font.pointSize: Appearance.font.size.smaller
font.family: Appearance.font.family.mono
elide: Qt.ElideRight
diff --git a/modules/bar/components/StatusIcons.qml b/modules/bar/components/StatusIcons.qml
index f1e3ffe..01284c6 100644
--- a/modules/bar/components/StatusIcons.qml
+++ b/modules/bar/components/StatusIcons.qml
@@ -48,7 +48,7 @@ StyledRect {
sourceComponent: StyledText {
animate: true
- text: Hyprland.kbLayout
+ text: Hypr.kbLayout
color: root.colour
font.family: Appearance.font.family.mono
}
diff --git a/modules/bar/components/workspaces/SpecialWorkspaces.qml b/modules/bar/components/workspaces/SpecialWorkspaces.qml
index fb31257..00beff9 100644
--- a/modules/bar/components/workspaces/SpecialWorkspaces.qml
+++ b/modules/bar/components/workspaces/SpecialWorkspaces.qml
@@ -14,8 +14,8 @@ Item {
id: root
required property ShellScreen screen
- readonly property HyprlandMonitor monitor: Hyprland.monitorFor(screen)
- readonly property string activeSpecial: (Config.bar.workspaces.perMonitorWorkspaces ? monitor : Hyprland.focusedMonitor)?.lastIpcObject.specialWorkspace.name ?? ""
+ readonly property HyprlandMonitor monitor: Hypr.monitorFor(screen)
+ readonly property string activeSpecial: (Config.bar.workspaces.perMonitorWorkspaces ? monitor : Hypr.focusedMonitor)?.lastIpcObject.specialWorkspace.name ?? ""
layer.enabled: true
layer.effect: ShaderEffect {
@@ -98,7 +98,7 @@ Item {
onCurrentIndexChanged: currentIndex = Qt.binding(() => model.values.findIndex(w => w.name === root.activeSpecial))
model: ScriptModel {
- values: Hyprland.workspaces.values.filter(w => w.name.startsWith("special:") && (!Config.bar.workspaces.perMonitorWorkspaces || w.monitor === root.monitor))
+ values: Hypr.workspaces.values.filter(w => w.name.startsWith("special:") && (!Config.bar.workspaces.perMonitorWorkspaces || w.monitor === root.monitor))
}
preferredHighlightBegin: 0
@@ -229,7 +229,7 @@ Item {
Repeater {
model: ScriptModel {
- values: Hyprland.toplevels.values.filter(c => c.workspace?.id === ws.wsId)
+ values: Hypr.toplevels.values.filter(c => c.workspace?.id === ws.wsId)
}
MaterialIcon {
@@ -357,9 +357,9 @@ Item {
const ws = view.itemAt(event.x, event.y);
if (ws?.modelData)
- Hyprland.dispatch(`togglespecialworkspace ${ws.modelData.name.slice(8)}`);
+ Hypr.dispatch(`togglespecialworkspace ${ws.modelData.name.slice(8)}`);
else
- Hyprland.dispatch("togglespecialworkspace special");
+ Hypr.dispatch("togglespecialworkspace special");
}
}
diff --git a/modules/bar/components/workspaces/Workspace.qml b/modules/bar/components/workspaces/Workspace.qml
index 6bd230b..8124024 100644
--- a/modules/bar/components/workspaces/Workspace.qml
+++ b/modules/bar/components/workspaces/Workspace.qml
@@ -80,7 +80,7 @@ ColumnLayout {
Repeater {
model: ScriptModel {
- values: Hyprland.toplevels.values.filter(c => c.workspace?.id === root.ws)
+ values: Hypr.toplevels.values.filter(c => c.workspace?.id === root.ws)
}
MaterialIcon {
diff --git a/modules/bar/components/workspaces/Workspaces.qml b/modules/bar/components/workspaces/Workspaces.qml
index 7b92ffa..c9a90e8 100644
--- a/modules/bar/components/workspaces/Workspaces.qml
+++ b/modules/bar/components/workspaces/Workspaces.qml
@@ -13,10 +13,10 @@ StyledClippingRect {
required property ShellScreen screen
- readonly property bool onSpecial: (Config.bar.workspaces.perMonitorWorkspaces ? Hyprland.monitorFor(screen) : Hyprland.focusedMonitor)?.lastIpcObject.specialWorkspace.name !== ""
- readonly property int activeWsId: Config.bar.workspaces.perMonitorWorkspaces ? (Hyprland.monitorFor(screen).activeWorkspace?.id ?? 1) : Hyprland.activeWsId
+ readonly property bool onSpecial: (Config.bar.workspaces.perMonitorWorkspaces ? Hypr.monitorFor(screen) : Hypr.focusedMonitor)?.lastIpcObject.specialWorkspace.name !== ""
+ readonly property int activeWsId: Config.bar.workspaces.perMonitorWorkspaces ? (Hypr.monitorFor(screen).activeWorkspace?.id ?? 1) : Hypr.activeWsId
- readonly property var occupied: Hyprland.workspaces.values.reduce((acc, curr) => {
+ readonly property var occupied: Hypr.workspaces.values.reduce((acc, curr) => {
acc[curr.id] = curr.lastIpcObject.windows > 0;
return acc;
}, {})
@@ -91,10 +91,10 @@ StyledClippingRect {
anchors.fill: layout
onClicked: event => {
const ws = layout.childAt(event.x, event.y).index + root.groupOffset + 1;
- if (Hyprland.activeWsId !== ws)
- Hyprland.dispatch(`workspace ${ws}`);
+ if (Hypr.activeWsId !== ws)
+ Hypr.dispatch(`workspace ${ws}`);
else
- Hyprland.dispatch("togglespecialworkspace special");
+ Hypr.dispatch("togglespecialworkspace special");
}
}