diff options
author | J-P Nurmi <jpnurmi@theqtcompany.com> | 2016-04-14 17:13:11 +0200 |
---|---|---|
committer | J-P Nurmi <jpnurmi@theqtcompany.com> | 2016-04-15 09:24:48 +0000 |
commit | b2e766c0cf4b5ae027f8d96202a9a9d29a7d84d4 (patch) | |
tree | 3973cf29c8cc6a2bbaf66b6b9a68f28e5935c1a1 /tests/auto/controls/data/tst_scrollindicator.qml | |
parent | 8ed4c6caf5fd464adf3c41192a97e47b48acb713 (diff) |
ScrollBar|Indicator: use QQmlInfo and don't crash with non-Flickables
Before:
ScrollBar must be attached to a Flickable QQuickItem(0x1774640)
The program has unexpectedly finished.
After:
qrc:/main.qml:9:5: QML : ScrollBar must be attached to a Flickable
Change-Id: I689d70744f64e209eacb4cb743ad64e904f29cd4
Reviewed-by: Mitch Curtis <mitch.curtis@theqtcompany.com>
Diffstat (limited to 'tests/auto/controls/data/tst_scrollindicator.qml')
-rw-r--r-- | tests/auto/controls/data/tst_scrollindicator.qml | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/tests/auto/controls/data/tst_scrollindicator.qml b/tests/auto/controls/data/tst_scrollindicator.qml index 99eef833..df0b7fd7 100644 --- a/tests/auto/controls/data/tst_scrollindicator.qml +++ b/tests/auto/controls/data/tst_scrollindicator.qml @@ -138,4 +138,9 @@ TestCase { container.destroy() } + + function test_warning() { + ignoreWarning(Qt.resolvedUrl("tst_scrollindicator.qml") + ":45:1: QML TestCase: ScrollIndicator must be attached to a Flickable") + testCase.ScrollIndicator.vertical = null + } } |