on xenial help sign in
tentative fix for fullscreen snaps
571fb62Lukáš Tinkl
qml/Notifications/Notification.qml+3
@@ -414,6 +414,9 @@ StyledItem {
414
414
415 onLoaded: {
415 onLoaded: {
416 notification.fullscreen = Qt.binding(function() { return fullscreen; });
416 notification.fullscreen = Qt.binding(function() { return fullscreen; });
417+ if (notification.fullscreen) {
418+ ListView.view.currentIndex = index
419+ }
417 }
420 }
418 onAccepted: {
421 onAccepted: {
419 notification.notification.invokeAction(actionRepeater.itemAt(0).actionId)
422 notification.notification.invokeAction(actionRepeater.itemAt(0).actionId)
qml/Notifications/Notifications.qml+10−6
@@ -69,13 +69,17 @@ ListView {
69 // FIXME: disabled all transitions because of LP: #1354406 workaround
69 // FIXME: disabled all transitions because of LP: #1354406 workaround
70 //layer.enabled: add.running || remove.running || populate.running
70 //layer.enabled: add.running || remove.running || populate.running
71
71
72+ readonly property int theIndex: index
73+ onTheIndexChanged: updateListTopMostIsFullscreen();
72− Component.onCompleted: {
74+ Component.onCompleted: updateListTopMostIsFullscreen();
73− if (index == 1) {
75+ onFullscreenChanged: updateListTopMostIsFullscreen();
74− notificationList.topmostIsFullscreen = fullscreen
76+
77+ function updateListTopMostIsFullscreen() {
78+ if (fullscreen) { // effectively hide any non-fullscreen snaps
79+ notificationList.positionViewAtIndex(index, ListView.Beginning);
80+ } else {
81+ notificationList.positionViewAtBeginning();
75 }
82 }
76− }
77−
78− onFullscreenChanged: {
79 // index 1 because 0 is the PlaceHolder...
83 // index 1 because 0 is the PlaceHolder...
80 if (index == 1) {
84 if (index == 1) {
81 notificationList.topmostIsFullscreen = fullscreen
85 notificationList.topmostIsFullscreen = fullscreen