Changeset View
Changeset View
Standalone View
Standalone View
applets/notifications/package/contents/ui/global/Globals.qml
Show First 20 Lines • Show All 263 Lines • ▼ Show 20 Line(s) | 263 | if (i > 0) { // however always show at least one popup | |||
---|---|---|---|---|---|
264 | if (popupLocation & Qt.AlignTop) { | 264 | if (popupLocation & Qt.AlignTop) { | ||
265 | visible = (popup.y + popup.height < screenRect.y + (screenRect.height * popupMaximumScreenFill)); | 265 | visible = (popup.y + popup.height < screenRect.y + (screenRect.height * popupMaximumScreenFill)); | ||
266 | } else { | 266 | } else { | ||
267 | visible = (popup.y > screenRect.y + (screenRect.height * (1 - popupMaximumScreenFill))); | 267 | visible = (popup.y > screenRect.y + (screenRect.height * (1 - popupMaximumScreenFill))); | ||
268 | } | 268 | } | ||
269 | } | 269 | } | ||
270 | 270 | | |||
271 | // TODO would be nice to hide popups when systray or panel controller is open | 271 | // TODO would be nice to hide popups when systray or panel controller is open | ||
272 | popup.visible = visible; | 272 | popup.visible = Qt.binding(function() { | ||
273 | return visible && !plasmoid.expanded; | ||||
274 | }); | ||||
273 | } | 275 | } | ||
274 | } | 276 | } | ||
275 | 277 | | |||
276 | property QtObject popupNotificationsModel: NotificationManager.Notifications { | 278 | property QtObject popupNotificationsModel: NotificationManager.Notifications { | ||
277 | limit: plasmoid ? (Math.ceil(plasmoid.availableScreenRect.height / (theme.mSize(theme.defaultFont).height * 4))) : 0 | 279 | limit: plasmoid ? (Math.ceil(plasmoid.availableScreenRect.height / (theme.mSize(theme.defaultFont).height * 4))) : 0 | ||
278 | showExpired: false | 280 | showExpired: false | ||
279 | showDismissed: false | 281 | showDismissed: false | ||
280 | blacklistedDesktopEntries: notificationSettings.popupBlacklistedApplications | 282 | blacklistedDesktopEntries: notificationSettings.popupBlacklistedApplications | ||
▲ Show 20 Lines • Show All 167 Lines • Show Last 20 Lines |