move notifications to top overlay
This commit is contained in:
parent
90b3cc22e2
commit
021c82f438
12 changed files with 106 additions and 172 deletions
|
|
@ -1,38 +0,0 @@
|
|||
pragma ComponentBehavior: Bound
|
||||
import Quickshell
|
||||
import QtQuick
|
||||
import Quickshell.Wayland
|
||||
import qs.settings
|
||||
import Quickshell.Hyprland
|
||||
Variants {
|
||||
model: Quickshell.screens
|
||||
delegate: WlrLayershell {
|
||||
required property ShellScreen modelData
|
||||
id: notiPopup
|
||||
exclusionMode: ExclusionMode.Ignore
|
||||
layer: WlrLayer.Overlay
|
||||
screen: modelData
|
||||
anchors {
|
||||
top: true
|
||||
right: true
|
||||
}
|
||||
margins.top: Config.cfg.bar.height + 8 + (Config.cfg.bar.floating ? 10 : 0)
|
||||
margins.right: 8
|
||||
implicitHeight: notiList.contentHeight
|
||||
implicitWidth: modelData.width / 6
|
||||
color: 'transparent'
|
||||
visible: NotiServer.notifications.values.length > 0
|
||||
|
||||
ListView {
|
||||
id: notiList
|
||||
anchors.fill: parent
|
||||
model: NotiServer.notifications
|
||||
spacing: 6
|
||||
delegate: NotiCard {
|
||||
required property var modelData
|
||||
nScreen: notiPopup.screen
|
||||
notification: modelData
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -5,7 +5,7 @@ import QtQuick
|
|||
|
||||
Singleton {
|
||||
id: root
|
||||
property alias notifications: server.trackedNotifications
|
||||
property list<Notification> notifications: server.trackedNotifications.values
|
||||
NotificationServer {
|
||||
id: server
|
||||
imageSupported: true
|
||||
|
|
|
|||
Loading…
Reference in a new issue