on xenial help sign in
fixup initially visible resize grips in staged mode
5e72a00Lukáš Tinkl
qml/Shell.qml+4−4
@@ -549,10 +549,10 @@ Item {
549 }
549 }
550
550
551 WindowControlsOverlay {
551 WindowControlsOverlay {
552− x: target ? target.x : -1
552+ x: target ? target.x : undefined
553− y: target ? target.y : -1
553+ y: target ? target.y : undefined
554− width: target ? target.width : 0
554+ width: target ? target.width : undefined
555− height: target? target.height : 0
555+ height: target? target.height : undefined
556 target: applicationsDisplayLoader.item && applicationsDisplayLoader.item.mainAppDelegate ? applicationsDisplayLoader.item.mainAppDelegate : null
556 target: applicationsDisplayLoader.item && applicationsDisplayLoader.item.mainAppDelegate ? applicationsDisplayLoader.item.mainAppDelegate : null
557 }
557 }
558
558
qml/Stages/DesktopStage.qml+1−1
@@ -585,7 +585,7 @@ AbstractStage {
585 screenHeight: appContainer.height
585 screenHeight: appContainer.height
586 leftMargin: root.leftMargin
586 leftMargin: root.leftMargin
587
587
588− onPressed: { appDelegate.focus = true; }
588+ onPressed: { mouse.accepted = false; appDelegate.focus = true; }
589
589
590 Component.onCompleted: {
590 Component.onCompleted: {
591 loadWindowState();
591 loadWindowState();
qml/Stages/WindowControlsOverlay.qml+12−6
@@ -34,6 +34,8 @@ Item {
34 // NB: for testing set to 2, not to clash with unity7 touch overlay controls
34 // NB: for testing set to 2, not to clash with unity7 touch overlay controls
35 minimumTouchPoints: 2
35 minimumTouchPoints: 2
36 maximumTouchPoints: minimumTouchPoints
36 maximumTouchPoints: minimumTouchPoints
37+ recognitionPeriod: 500
38+ releaseRejectPeriod: 500
37
39
38 readonly property bool recognizedPress: status == TouchGestureArea.Recognized &&
40 readonly property bool recognizedPress: status == TouchGestureArea.Recognized &&
39 touchPoints.length >= minimumTouchPoints &&
41 touchPoints.length >= minimumTouchPoints &&
@@ -45,6 +47,10 @@ Item {
45 overlayTimer.start();
47 overlayTimer.start();
46 }
48 }
47 }
49 }
50+
51+ onStatusChanged: {
52+ print("Status changed:", status)
53+ }
48 }
54 }
49
55
50 // dismiss timer
56 // dismiss timer
@@ -136,7 +142,7 @@ Item {
136 ResizeGrip { // top left
142 ResizeGrip { // top left
137 anchors.horizontalCenter: parent.left
143 anchors.horizontalCenter: parent.left
138 anchors.verticalCenter: parent.top
144 anchors.verticalCenter: parent.top
139− visible: !overlay.anyMaximized
145+ visible: target && !overlay.anyMaximized
140 resizeTarget: priv.resizeArea
146 resizeTarget: priv.resizeArea
141 }
147 }
142
148
@@ -144,7 +150,7 @@ Item {
144 anchors.horizontalCenter: parent.horizontalCenter
150 anchors.horizontalCenter: parent.horizontalCenter
145 anchors.verticalCenter: parent.top
151 anchors.verticalCenter: parent.top
146 rotation: 45
152 rotation: 45
147− visible: !overlay.anyMaximized
153+ visible: target && !overlay.anyMaximized
148 resizeTarget: priv.resizeArea
154 resizeTarget: priv.resizeArea
149 }
155 }
150
156
@@ -152,7 +158,7 @@ Item {
152 anchors.horizontalCenter: parent.right
158 anchors.horizontalCenter: parent.right
153 anchors.verticalCenter: parent.top
159 anchors.verticalCenter: parent.top
154 rotation: 90
160 rotation: 90
155− visible: !overlay.anyMaximized
161+ visible: target && !overlay.anyMaximized
156 resizeTarget: priv.resizeArea
162 resizeTarget: priv.resizeArea
157 }
163 }
158
164
@@ -167,7 +173,7 @@ Item {
167 ResizeGrip { // bottom right
173 ResizeGrip { // bottom right
168 anchors.horizontalCenter: parent.right
174 anchors.horizontalCenter: parent.right
169 anchors.verticalCenter: parent.bottom
175 anchors.verticalCenter: parent.bottom
170− visible: !overlay.anyMaximized
176+ visible: target && !overlay.anyMaximized
171 resizeTarget: priv.resizeArea
177 resizeTarget: priv.resizeArea
172 }
178 }
173
179
@@ -175,7 +181,7 @@ Item {
175 anchors.horizontalCenter: parent.horizontalCenter
181 anchors.horizontalCenter: parent.horizontalCenter
176 anchors.verticalCenter: parent.bottom
182 anchors.verticalCenter: parent.bottom
177 rotation: 45
183 rotation: 45
178− visible: !overlay.anyMaximized
184+ visible: target && !overlay.anyMaximized
179 resizeTarget: priv.resizeArea
185 resizeTarget: priv.resizeArea
180 }
186 }
181
187
@@ -183,7 +189,7 @@ Item {
183 anchors.horizontalCenter: parent.left
189 anchors.horizontalCenter: parent.left
184 anchors.verticalCenter: parent.bottom
190 anchors.verticalCenter: parent.bottom
185 rotation: 90
191 rotation: 90
186− visible: !overlay.anyMaximized
192+ visible: target && !overlay.anyMaximized
187 resizeTarget: priv.resizeArea
193 resizeTarget: priv.resizeArea
188 }
194 }
189
195