83 lines
1.4 KiB
QML
83 lines
1.4 KiB
QML
//@ pragma ShellId shell
|
|
|
|
import Quickshell
|
|
import Quickshell.Io
|
|
import Quickshell.Wayland
|
|
import QtQuick
|
|
import QtQuick.Layouts
|
|
import "screenshot" as Screenshot
|
|
import "bar" as Bar
|
|
import "lock" as Lock
|
|
import "notifications" as Notifs
|
|
import "launcher" as Launcher
|
|
import "background"
|
|
|
|
ShellRoot {
|
|
id: root
|
|
|
|
Component.onCompleted: [Lock.Controller, Launcher.Controller.init()]
|
|
|
|
Process {
|
|
command: ["mkdir", "-p", ShellGlobals.rtpath]
|
|
running: true
|
|
}
|
|
|
|
LazyLoader {
|
|
id: screenshot
|
|
loading: true
|
|
|
|
Screenshot.Controller {
|
|
}
|
|
}
|
|
|
|
Connections {
|
|
target: ShellIpc
|
|
|
|
function onScreenshot() {
|
|
screenshot.item.shooting = true;
|
|
}
|
|
}
|
|
|
|
Notifs.NotificationOverlay {
|
|
screen: Quickshell.screens.find(s => s.name == "DP-1")
|
|
bar: root.bars.find(b => b.screen == screen)
|
|
}
|
|
|
|
property var bars: []
|
|
|
|
Variants {
|
|
model: Quickshell.screens
|
|
|
|
Scope {
|
|
property var modelData
|
|
|
|
Bar.Bar {
|
|
screen: modelData
|
|
Component.onCompleted: root.bars = [...root.bars, this]
|
|
Component.onDestruction: root.bars = root.bars.filter(b => b == this)
|
|
}
|
|
|
|
PanelWindow {
|
|
id: window
|
|
|
|
screen: modelData
|
|
|
|
exclusionMode: ExclusionMode.Ignore
|
|
WlrLayershell.layer: WlrLayer.Background
|
|
WlrLayershell.namespace: "shell:background"
|
|
|
|
anchors {
|
|
top: true
|
|
bottom: true
|
|
left: true
|
|
right: true
|
|
}
|
|
|
|
BackgroundImage {
|
|
anchors.fill: parent
|
|
screen: window.screen
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|