~attente/unity8/1634508

« back to all changes in this revision

Viewing changes to tests/qmltests/Greeter/tst_WideView.qml

  • Committer: Bileto Bot
  • Author(s): Michael Terry
  • Date: 2016-09-22 07:39:48 UTC
  • mfrom: (2552.7.2 greeter-no-lockscreen)
  • Revision ID: ci-train-bot@canonical.com-20160922073948-c2h0juru3m7tn135
Switch from lockscreen PIN pad to a passcode entry box that uses the OSK.

Approved by: Albert Astals Cid

Show diffs side-by-side

added added

removed removed

Lines of Context:
641
641
 
642
642
            keyboardVisibleCheckBox.checked = true;
643
643
 
644
 
            tryCompare(loginList, "height", view.height - view.inputMethod.keyboardRectangle.height);
 
644
            var halfway = (view.height - loginList.highlightedHeight) / 2;
 
645
            var halfwayWithOsk = halfway - view.inputMethod.keyboardRectangle.height / 2;
 
646
            tryCompare(loginList, "boxVerticalOffset", halfwayWithOsk);
 
647
 
 
648
            var highlightItem = findChild(loginList, "highlightItem");
645
649
            tryCompareFunction( function() {
646
 
                var loginListRect = loginList.mapToItem(view, 0, 0, loginList.width, loginList.height);
647
 
                return loginListRect.y + loginListRect.height <= view.inputMethod.keyboardRectangle.y;
 
650
                var highlightRect = highlightItem.mapToItem(view, 0, 0, highlightItem.width, highlightItem.height);
 
651
                return highlightRect.y + highlightRect.height <= view.inputMethod.keyboardRectangle.y;
648
652
            }, true);
649
653
 
650
654
            // once the vkb goes away, loginList goes back to its full height
651
655
 
652
656
            keyboardVisibleCheckBox.checked = false;
653
657
 
654
 
            tryCompare(loginList, "height", view.height);
 
658
            tryCompare(loginList, "boxVerticalOffset", halfway);
655
659
        }
656
660
 
657
661
        function test_passphrase() {