diff options
author | J-P Nurmi <jpnurmi@qt.io> | 2016-05-09 16:09:07 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@qt.io> | 2016-05-10 12:47:26 +0000 |
commit | 28b2f4b090f971c79bc1e2f9afa2b1424c0bd642 (patch) | |
tree | d245cc0f0d658e8829cccb7ebd941300286083c6 /tests | |
parent | 0935e65a50f8a90569e300021ccaafabbead4e79 (diff) |
ComboBox: restore the old popup behavior
Make the Popup follow ComboBox outside the horizontal screen bounds.
Setting an explicit width instead of implicit width does exactly this.
Change-Id: I46f4e5e40d5012929badf39d50d70b9a7811f455
Reviewed-by: Mitch Curtis <mitch.curtis@qt.io>
Diffstat (limited to 'tests')
-rw-r--r-- | tests/auto/controls/data/tst_combobox.qml | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/auto/controls/data/tst_combobox.qml b/tests/auto/controls/data/tst_combobox.qml index de5b1ad9..38858998 100644 --- a/tests/auto/controls/data/tst_combobox.qml +++ b/tests/auto/controls/data/tst_combobox.qml @@ -519,6 +519,14 @@ TestCase { compare(control.popup.visible, true) verify(control.popup.contentItem.y < control.y) + // follow the control outside the horizontal window bounds + control.x = -control.width / 2 + compare(control.x, -control.width / 2) + compare(control.popup.contentItem.parent.x, -control.width / 2) + control.x = testCase.width - control.width / 2 + compare(control.x, testCase.width - control.width / 2) + compare(control.popup.contentItem.parent.x, testCase.width - control.width / 2) + control.destroy() } |