Skip to content

Commit

Permalink
Add Alarm Bell in Status Bar
Browse files Browse the repository at this point in the history
  • Loading branch information
MikeTrahearn-Qinetic committed Dec 19, 2024
1 parent 9ee8cec commit 7cdf272
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 1 deletion.
8 changes: 7 additions & 1 deletion components/StatusBar.qml
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,6 @@ Rectangle {
}
}


Label {
id: clockLabel
anchors.centerIn: parent
Expand Down Expand Up @@ -188,6 +187,13 @@ Rectangle {
height: Theme.geometry_status_bar_gsmModem_icon_height
anchors.verticalCenter: parent.verticalCenter
}

CP.IconImage {
anchors.verticalCenter: parent.verticalCenter
color: Theme.color_font_primary
source: "qrc:/images/notifications.svg"
visible: Global.notifications.activeAlarms.count > 0
}
}

Row {
Expand Down
7 changes: 7 additions & 0 deletions data/Notifications.qml
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,13 @@ QtObject {
// only alarms
type: VenusOS.Notification_Alarm
}
readonly property NotificationSortFilterProxyModel activeAlarms: NotificationSortFilterProxyModel {
sourceModel: allNotificationsModel
active: true
// whether unacknowledged or not
// only alarms
type: VenusOS.Notification_Alarm
}

readonly property bool alarm: !!_alarm.value
readonly property bool alert: !!_alert.value
Expand Down

0 comments on commit 7cdf272

Please sign in to comment.