on xenial help sign in
flow up
db48541Nick Dedekind
Panel/IndicatorRow.qml+31
@@ -27,6 +27,7 @@ Item {
27 property alias row: row
27 property alias row: row
28 property QtObject indicatorsModel: null
28 property QtObject indicatorsModel: null
29 property var visibleIndicators: defined
29 property var visibleIndicators: defined
30+ property int overFlowWidth: width
30
31
31 width: units.gu(40)
32 width: units.gu(40)
32 height: units.gu(3)
33 height: units.gu(3)
@@ -59,6 +60,8 @@ Item {
59 height: indicatorRow.height
60 height: indicatorRow.height
60 width: indicatorItem.width
61 width: indicatorItem.width
61 visible: indicatorItem.indicatorVisible
62 visible: indicatorItem.indicatorVisible
63+ y: 0
64+ state: "standard"
62
65
63 property int ownIndex: index
66 property int ownIndex: index
64 property alias highlighted: indicatorItem.highlighted
67 property alias highlighted: indicatorItem.highlighted
@@ -103,6 +106,34 @@ Item {
103 duration: (rowRepeater.count - Math.abs(indicatorRow.currentItemIndex - index)) * (500/rowRepeater.count)
106 duration: (rowRepeater.count - Math.abs(indicatorRow.currentItemIndex - index)) * (500/rowRepeater.count)
104 }
107 }
105 }
108 }
109+ states: [
110+ State {
111+ name: "standard"
112+ when: row.width - itemWrapper.x <= overFlowWidth
113+ PropertyChanges { target: itemWrapper; y: 0 }
114+ },
115+ State {
116+ name: "overflow"
117+ when: row.width - itemWrapper.x > overFlowWidth
118+ PropertyChanges { target: itemWrapper; y: -indicatorRow.height }
119+ }
120+ ]
121+ transitions: [
122+ Transition {
123+ from: "standard"; to: "overflow"
124+ StandardAnimation {
125+ target: itemWrapper
126+ property: "y"
127+ }
128+ },
129+ Transition {
130+ from: "overflow"; to: "standard"
131+ StandardAnimation {
132+ target: itemWrapper
133+ property: "y"
134+ }
135+ }
136+ ]
106 }
137 }
107 }
138 }
108 }
139 }
Panel/Indicators.qml+1
@@ -28,6 +28,7 @@ Showable {
28 property real openedHeight: units.gu(71)
28 property real openedHeight: units.gu(71)
29 property int panelHeight: units.gu(3)
29 property int panelHeight: units.gu(3)
30 property bool pinnedMode: true //should be set true if indicators menu can cover whole screen
30 property bool pinnedMode: true //should be set true if indicators menu can cover whole screen
31+ property alias overFlowWidth: indicatorRow.overFlowWidth
31
32
32 property int hintValue
33 property int hintValue
33 readonly property int lockThreshold: openedHeight / 2
34 readonly property int lockThreshold: openedHeight / 2
Panel/Panel.qml+1−27
@@ -82,6 +82,7 @@ Item {
82 panelHeight: __panelMinusSeparatorLineHeight
82 panelHeight: __panelMinusSeparatorLineHeight
83 openedHeight: parent.height + (pinnedMode ? 0 : root.panelHeight)
83 openedHeight: parent.height + (pinnedMode ? 0 : root.panelHeight)
84 pinnedMode: !fullscreenMode
84 pinnedMode: !fullscreenMode
85+ overFlowWidth: search.state=="hidden" ? parent.width : parent.width - search.width
85
86
86 property real unitProgress: (height - panelHeight) / (openedHeight - panelHeight)
87 property real unitProgress: (height - panelHeight) / (openedHeight - panelHeight)
87 }
88 }
@@ -109,33 +110,6 @@ Item {
109 source: "graphics/rectangular_dropshadow.sci"
110 source: "graphics/rectangular_dropshadow.sci"
110 }
111 }
111
112
112− PanelBackground {
113− id: backgroundSearch
114− height: __panelMinusSeparatorLineHeight
115− y: panelBackground.y
116− anchors {
117− left: parent.left
118− right: search.right
119− }
120− clip: false
121− opacity: search.state=="visible" ? 1.0 : 0.0
122−
123− Rectangle {
124− id: backgroundGradient
125− anchors {
126− left: parent.right
127− }
128− width: __panelMinusSeparatorLineHeight
129− height: __panelMinusSeparatorLineHeight
130− rotation: 90
131− gradient: Gradient {
132− GradientStop { position: 0.0; color: "transparent" }
133− GradientStop { position: 1.0; color: backgroundSearch.color }
134− }
135− }
136− Behavior on opacity { StandardAnimation {} }
137− }
138−
139 SearchIndicator {
113 SearchIndicator {
140 id: search
114 id: search
141 objectName: "search"
115 objectName: "search"