Notification: add urgency and alter the look when it's a critical notification.
This commit is contained in:
parent
411ed72436
commit
73ec07491f
2 changed files with 4 additions and 0 deletions
|
|
@ -32,6 +32,7 @@ PanelWindow {
|
||||||
appName: notification.appName || "Notification",
|
appName: notification.appName || "Notification",
|
||||||
summary: notification.summary || "",
|
summary: notification.summary || "",
|
||||||
body: notification.body || "",
|
body: notification.body || "",
|
||||||
|
urgency: notification.urgency || 0,
|
||||||
rawNotification: notification,
|
rawNotification: notification,
|
||||||
appeared: false,
|
appeared: false,
|
||||||
dismissed: false
|
dismissed: false
|
||||||
|
|
@ -84,6 +85,8 @@ PanelWindow {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
color: Theme.backgroundPrimary
|
color: Theme.backgroundPrimary
|
||||||
radius: 20
|
radius: 20
|
||||||
|
border.color: model.urgency == 2 ? Theme.warning : Theme.outline
|
||||||
|
border.width: 1
|
||||||
|
|
||||||
property bool appeared: model.appeared
|
property bool appeared: model.appeared
|
||||||
property bool dismissed: model.dismissed
|
property bool dismissed: model.dismissed
|
||||||
|
|
|
||||||
|
|
@ -62,6 +62,7 @@ Scope {
|
||||||
appName: notification.appName || "Notification",
|
appName: notification.appName || "Notification",
|
||||||
summary: notification.summary || "",
|
summary: notification.summary || "",
|
||||||
body: notification.body || "",
|
body: notification.body || "",
|
||||||
|
urgency: notification.urgency,
|
||||||
timestamp: Date.now()
|
timestamp: Date.now()
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue