on xenial help sign in
Make the indicators left/right work just after opening indicators too
e9b688aAlbert Astals Cid
qml/Panel/IndicatorsMenu.qml+1
@@ -369,6 +369,7 @@ Showable {
369 State {
369 State {
370 name: "commit"
370 name: "commit"
371 extend: "locked"
371 extend: "locked"
372+ PropertyChanges { target: root; focus: true }
372 PropertyChanges { target: bar; interactive: true }
373 PropertyChanges { target: bar; interactive: true }
373 PropertyChanges {
374 PropertyChanges {
374 target: d;
375 target: d;
tests/qmltests/Panel/tst_IndicatorsMenu.qml+11−2
@@ -304,14 +304,23 @@ IndicatorTest {
304 indicatorsMenu.hide();
304 indicatorsMenu.hide();
305 }
305 }
306
306
307+ function test_keyboardNavigation_data() {
308+ return [
309+ {tag: "tab to start", doTab: false},
310+ {tag: "no tab to start", doTab: true}
311+ ]
312+ }
313+
307− function test_keyboardNavigation() {
314+ function test_keyboardNavigation(data) {
308 var indicatorsBar = findChild(indicatorsMenu, "indicatorsBar");
315 var indicatorsBar = findChild(indicatorsMenu, "indicatorsBar");
309
316
310 indicatorsMenu.show();
317 indicatorsMenu.show();
311 indicatorsBar.setCurrentItemIndex(0);
318 indicatorsBar.setCurrentItemIndex(0);
312 tryCompare(indicatorsMenu, "fullyOpened", true);
319 tryCompare(indicatorsMenu, "fullyOpened", true);
313
320
321+ if (data.doTab) {
314− keyClick(Qt.Key_Tab);
322+ keyClick(Qt.Key_Tab);
323+ }
315
324
316 keyClick(Qt.Key_Right);
325 keyClick(Qt.Key_Right);
317 tryCompare(indicatorsBar, "currentItemIndex", 1);
326 tryCompare(indicatorsBar, "currentItemIndex", 1);