Merge branch 'Plasma/5.10'

wilder-5.14
Kai Uwe Broulik 9 years ago
commit fd526cd722
  1. 48
      applets/notifications/package/contents/ui/NotificationIcon.qml
  2. 8
      applets/notifications/package/contents/ui/main.qml

@ -31,7 +31,17 @@ Item {
height: width
svg: notificationSvg
elementId: "notification-disabled"
elementId: {
if (totalCount > 0) {
if (jobs && jobs.count > 0) {
return "notification-progress-inactive"
} else {
return "notification-empty"
}
}
return "notification-disabled"
}
state: notificationsApplet.state
@ -88,7 +98,7 @@ Item {
font.pointSize: 100
fontSizeMode: Text.Fit
minimumPointSize: theme.smallestFont.pointSize
visible: false
visible: notificationsApplet.totalCount > 0
Connections {
target: notificationsApplet
@ -151,39 +161,5 @@ Item {
onPressed: wasExpanded = plasmoid.expanded
onClicked: plasmoid.expanded = !wasExpanded
}
states: [
State {
name: "default"
PropertyChanges {
target: notificationSvgItem
elementId: "notification-disabled"
}
PropertyChanges {
target: notificationCountLabel
visible: false
}
PropertyChanges {
target: plasmoid
status: PlasmaCore.Types.PassiveStatus
}
},
State {
name: "new-notifications"
PropertyChanges {
target: notificationSvgItem
elementId: jobs.count > 0 ? "notification-progress-inactive" : "notification-empty"
}
PropertyChanges {
target: notificationCountLabel
visible: true
}
PropertyChanges {
target: plasmoid
status: PlasmaCore.Types.ActiveStatus
}
}
]
}
}

@ -88,16 +88,10 @@ MouseEventListener {
}
}
state: "default"
hoverEnabled: !UiProperties.touchInput
onTotalCountChanged: {
print(" totalCountChanged " + totalCount)
if (totalCount > 0) {
state = "new-notifications"
} else {
state = "default"
//plasmoid.hidePopup()
if (!totalCount) {
plasmoid.expanded = false;
}
}

Loading…
Cancel
Save