diff options
author | Marco Martin <[email protected]> | 2016-01-11 14:57:56 +0100 |
---|---|---|
committer | Marco Martin <[email protected]> | 2016-01-12 16:34:22 +0000 |
commit | fb0e8833fde306eebc31b78722d8f0178b817eb7 (patch) | |
tree | 5a0a6c1d4ef3f2392d3615beb0d93fd862455bd7 /src/controls/ScrollView.qml | |
parent | 73bf08d2cdabb8499acf9c63b942f8df8ac0c7c1 (diff) |
Check for __style existence before accessing it
Since __style is loaded by a Loader, very early in initialization, it
may still be null. so check for its existence before accessing it.
When it will be fully loaded the property binding will cause a
reevaluation with the proper values.
This fixes __wheelScrollLines never being loaded from the style.
Change-Id: I5967265a4d31e1be2c972daa79b9389fecc25933
Reviewed-by: J-P Nurmi <[email protected]>
Diffstat (limited to 'src/controls/ScrollView.qml')
-rw-r--r-- | src/controls/ScrollView.qml | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/controls/ScrollView.qml b/src/controls/ScrollView.qml index a6eaed825..d2e61c81c 100644 --- a/src/controls/ScrollView.qml +++ b/src/controls/ScrollView.qml @@ -286,7 +286,7 @@ FocusScope { // comes originally from QTextEdit, which sets 20px steps by default, as well as // QQuickWheelArea. // TODO: centralize somewhere, QPlatformTheme? - scrollSpeed: 20 * (__style.__wheelScrollLines || 1) + scrollSpeed: 20 * (__style && __style.__wheelScrollLines || 1) Connections { target: flickableItem |