on xenial help sign in
edge hinting tweaks

- change edge hinting behavior to only happen on onPressed and immediately snap back - fix edge hinting to not happen if the Greeter is locked

commit90ada3c77a856edff315d009ecf16cc1dfd8bbae authorMichael Zanetti <michael.zanetti@canonical.com> dateFri 28 Jun 2013, 14:07 (13 years ago) parent7718edc
3 files changed+11−7
Greeter/Greeter.qml+2−2 Launcher/Launcher.qml+3−4 Shell.qml+6−1
Greeter/Greeter.qml+2−2
@@ -48,7 +48,7 @@ Showable {
4848 signal unlocked(int uid)
4949
5050 onRightTeaserPressedChanged: {
51− if (rightTeaserPressed) {
51+ if (rightTeaserPressed && !locked) {
5252 teasingTimer.start();
5353 }
5454 }
@@ -81,7 +81,7 @@ Showable {
8181 states: [
8282 State {
8383 name: "teasing"
84− when: greeter.rightTeaserPressed || teasingTimer.running
84+ when: teasingTimer.running
8585 PropertyChanges {
8686 target: greeter
8787 x: -units.gu(2)
Launcher/Launcher.qml+3−4
@@ -25,7 +25,6 @@ Item {
2525
2626 property bool available: true // can be used to disable all interactions
2727
28− property bool teasing: false
2928 property int panelWidth: units.gu(8.5)
3029 property int dragAreaWidth: units.gu(1)
3130 property real progress: dragArea.dragging && dragArea.touchX > panel.width ? dragArea.touchX : 0
@@ -58,8 +57,8 @@ Item {
5857 animateTimer.start();
5958 }
6059
61− onTeasingChanged: {
62− if (teasing) {
60+ function tease() {
61+ if (available) {
6362 teaseTimer.start();
6463 }
6564 }
@@ -244,7 +243,7 @@ Item {
244243 },
245244 State {
246245 name: "teasing"
247− when: root.teasing || teaseTimer.running
246+ when: teaseTimer.running
248247 PropertyChanges {
249248 target: panel
250249 x: -root.panelWidth + units.gu(2)
Shell.qml+6−1
@@ -439,6 +439,12 @@ FocusScope {
439439 var bgPath = greeter.model.data(uid, LightDM.UserRoles.BackgroundPathRole)
440440 shell.background = bgPath ? bgPath : default_background
441441 }
442+
443+ onLeftTeaserPressedChanged: {
444+ if (leftTeaserPressed) {
445+ launcher.tease();
446+ }
447+ }
442448 }
443449
444450 InputFilterArea {
@@ -532,7 +538,6 @@ FocusScope {
532538 width: parent.width
533539 dragAreaWidth: shell.edgeSize
534540 available: !greeter.locked
535− teasing: available && greeter.leftTeaserPressed
536541 onDashItemSelected: {
537542 greeter.hide()
538543 // Animate if moving between application and dash