Changeset View
Changeset View
Standalone View
Standalone View
tests/pointerconstraintstest.qml
Show First 20 Lines • Show All 73 Lines • ▼ Show 20 Line(s) | 26 | ColumnLayout { | |||
---|---|---|---|---|---|
74 | 74 | | |||
75 | function activRect() { | 75 | function activRect() { | ||
76 | if (fullWindowChck.checked) { | 76 | if (fullWindowChck.checked) { | ||
77 | return Qt.rect(0, 0, -1, -1); | 77 | return Qt.rect(0, 0, -1, -1); | ||
78 | } | 78 | } | ||
79 | return activArea.rect(); | 79 | return activArea.rect(); | ||
80 | } | 80 | } | ||
81 | 81 | | |||
82 | Connections { | ||||
83 | target: org_kde_kwin_tests_pointerconstraints_backend | ||||
84 | onForceSurfaceCommit: { | ||||
85 | forceCommitRect.visible = true | ||||
86 | } | ||||
87 | } | ||||
88 | | ||||
89 | Rectangle { | ||||
90 | id: forceCommitRect | ||||
91 | width: 10 | ||||
92 | height: 10 | ||||
93 | color: "red" | ||||
94 | visible: false | ||||
95 | | ||||
96 | Timer { | ||||
97 | interval: 500 | ||||
98 | running: forceCommitRect.visible | ||||
99 | repeat: false | ||||
100 | onTriggered: forceCommitRect.visible = false; | ||||
101 | } | ||||
102 | } | ||||
103 | | ||||
82 | GridLayout { | 104 | GridLayout { | ||
83 | columns: 2 | 105 | columns: 2 | ||
84 | rowSpacing: 10 | 106 | rowSpacing: 10 | ||
85 | columnSpacing: 10 | 107 | columnSpacing: 10 | ||
86 | 108 | | |||
87 | Button { | 109 | Button { | ||
88 | id: lockButton | 110 | id: lockButton | ||
89 | text: "Lock pointer" | 111 | text: "Lock pointer" | ||
Show All 26 Lines | 137 | CheckBox { | |||
116 | id: confBeforeHideChck | 138 | id: confBeforeHideChck | ||
117 | text: "Confine first, then hide" | 139 | text: "Confine first, then hide" | ||
118 | checked: false | 140 | checked: false | ||
119 | visible: !root.waylandNative | 141 | visible: !root.waylandNative | ||
120 | } | 142 | } | ||
121 | } | 143 | } | ||
122 | 144 | | |||
123 | CheckBox { | 145 | CheckBox { | ||
146 | id: lockHintChck | ||||
147 | text: "Send position hint on lock" | ||||
148 | checked: root.waylandNative | ||||
149 | enabled: root.waylandNative | ||||
150 | onCheckedChanged: org_kde_kwin_tests_pointerconstraints_backend.lockHint = checked; | ||||
151 | } | ||||
152 | CheckBox { | ||||
124 | id: restrAreaChck | 153 | id: restrAreaChck | ||
125 | text: "Restrict input area (not yet implemented)" | 154 | text: "Restrict input area (not yet implemented)" | ||
126 | enabled: false | 155 | enabled: false | ||
127 | } | 156 | } | ||
128 | CheckBox { | 157 | CheckBox { | ||
129 | id: fullWindowChck | 158 | id: fullWindowChck | ||
130 | text: "Full window area activates" | 159 | text: "Full window area activates" | ||
131 | checked: !root.waylandNative | 160 | checked: !root.waylandNative | ||
▲ Show 20 Lines • Show All 59 Lines • Show Last 20 Lines |