Changeset View
Changeset View
Standalone View
Standalone View
lookandfeel/contents/lockscreen/LockScreenUi.qml
Show First 20 Lines • Show All 63 Lines • ▼ Show 20 Line(s) | 31 | PlasmaCore.ColorScope { | |||
---|---|---|---|---|---|
64 | 64 | | |||
65 | Loader { | 65 | Loader { | ||
66 | id: changeSessionComponent | 66 | id: changeSessionComponent | ||
67 | active: false | 67 | active: false | ||
68 | source: "ChangeSession.qml" | 68 | source: "ChangeSession.qml" | ||
69 | visible: false | 69 | visible: false | ||
70 | } | 70 | } | ||
71 | 71 | | |||
72 | MouseArea { | 72 | MouseArea { | ||
broulik: How about
```
cursorShape: uiVisible ? Qt.ArrowCursor : Qt.BlankCursor
``` | |||||
The problem was that I first had to move the mouse to enter the MouseArea. I.e. when the Screenlocker is activated by timer the cursor is visible until first time the mouse is moved and then the fade out timer triggers afterwards. romangg: The problem was that I first had to move the mouse to enter the MouseArea. I.e. when the… | |||||
shouldn't that mousearea cover the whole area? if cursorshape doesn't work for a thing that appears under the cursor that's definitely a mousearea bug mart: shouldn't that mousearea cover the whole area? if cursorshape doesn't work for a thing that… | |||||
You are right, that it should cover the whole area, if it could be used. I added a comment to D13206 with a link to the Qt bug why it can't be used. romangg: You are right, that it should cover the whole area, if it could be used. I added a comment to… | |||||
73 | id: lockScreenRoot | 73 | id: lockScreenRoot | ||
74 | 74 | | |||
75 | property bool uiVisible: false | 75 | property bool uiVisible: false | ||
76 | property bool blockUI: mainStack.depth > 1 || mainBlock.mainPasswordBox.text.length > 0 || inputPanel.keyboardActive | 76 | property bool blockUI: mainStack.depth > 1 || mainBlock.mainPasswordBox.text.length > 0 || inputPanel.keyboardActive | ||
77 | 77 | | |||
78 | x: parent.x | 78 | x: parent.x | ||
79 | y: parent.y | 79 | y: parent.y | ||
80 | width: parent.width | 80 | width: parent.width | ||
81 | height: parent.height | 81 | height: parent.height | ||
82 | hoverEnabled: true | 82 | hoverEnabled: true | ||
83 | drag.filterChildren: true | 83 | drag.filterChildren: true | ||
84 | onPressed: uiVisible = true; | 84 | onPressed: uiVisible = true; | ||
85 | onPositionChanged: uiVisible = true; | 85 | onPositionChanged: uiVisible = true; | ||
86 | onUiVisibleChanged: { | 86 | onUiVisibleChanged: { | ||
87 | if (blockUI) { | 87 | if (blockUI) { | ||
88 | fadeoutTimer.running = false; | 88 | fadeoutTimer.running = false; | ||
89 | org_kde_plasma_screenlocker_greeter_app.cursorHidden = false; | ||||
89 | } else if (uiVisible) { | 90 | } else if (uiVisible) { | ||
90 | fadeoutTimer.restart(); | 91 | fadeoutTimer.restart(); | ||
92 | org_kde_plasma_screenlocker_greeter_app.cursorHidden = false; | ||||
93 | } else { | ||||
94 | org_kde_plasma_screenlocker_greeter_app.cursorHidden = true; | ||||
91 | } | 95 | } | ||
92 | } | 96 | } | ||
93 | onBlockUIChanged: { | 97 | onBlockUIChanged: { | ||
94 | if (blockUI) { | 98 | if (blockUI) { | ||
95 | fadeoutTimer.running = false; | 99 | fadeoutTimer.running = false; | ||
96 | uiVisible = true; | 100 | uiVisible = true; | ||
97 | } else { | 101 | } else { | ||
98 | fadeoutTimer.restart(); | 102 | fadeoutTimer.restart(); | ||
▲ Show 20 Lines • Show All 358 Lines • ▼ Show 20 Line(s) | |||||
457 | } | 461 | } | ||
458 | 462 | | |||
459 | Component.onCompleted: { | 463 | Component.onCompleted: { | ||
460 | // version support checks | 464 | // version support checks | ||
461 | if (root.interfaceVersion < 1) { | 465 | if (root.interfaceVersion < 1) { | ||
462 | // ksmserver of 5.4, with greeter of 5.5 | 466 | // ksmserver of 5.4, with greeter of 5.5 | ||
463 | root.viewVisible = true; | 467 | root.viewVisible = true; | ||
464 | } | 468 | } | ||
469 | org_kde_plasma_screenlocker_greeter_app.cursorHidden = true; | ||||
465 | } | 470 | } | ||
466 | } | 471 | } |
How about