diff options
author | Pierre Rossi <pierre.rossi@theqtcompany.com> | 2014-12-11 17:17:01 +0100 |
---|---|---|
committer | Pierre Rossi <pierre.rossi@theqtcompany.com> | 2014-12-19 16:02:08 +0100 |
commit | 54e05945b0ec4328b9d56b3b6a9886fc24ad3e6a (patch) | |
tree | 1adab9920626fef489188cf4c7adc41195988a43 /tests/auto/quick/qmltests/qmltests.pro | |
parent | 90e54b47974fe7818f7aa1bdd434e062e89458a1 (diff) |
Don't crash when using onEditingFinished
In order to stay in line with the behavior expected by Chromium, we
focus the view on load. This is problematic when relying on the
editingFinished signal of text inputs in QML, as it is fired both when
pressing enter and when losing focus.
In our case, this would lead to reentering into load and in turn
QQuickWindowPrivate::setFocusInScope, and when returning from the outer
call, QQuickWindow would try to access the RWHVQtDelegateQuick from the
first load through a now dangling pointer.
It seems preferable to guard WebContentsAdapter::load against recursion.
Adds a simple autotest that covers the crash scenario.
Task-number: QTBUG-42929
Change-Id: Ib3bf9f421b1a91645b3e0e9aa658f2a3646d9caf
Reviewed-by: Andras Becsi <andras.becsi@theqtcompany.com>
Reviewed-by: Zeno Albisser <zeno.albisser@digia.com>
Diffstat (limited to 'tests/auto/quick/qmltests/qmltests.pro')
-rw-r--r-- | tests/auto/quick/qmltests/qmltests.pro | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/tests/auto/quick/qmltests/qmltests.pro b/tests/auto/quick/qmltests/qmltests.pro index b40ef3b8c..33a864cf1 100644 --- a/tests/auto/quick/qmltests/qmltests.pro +++ b/tests/auto/quick/qmltests/qmltests.pro @@ -23,6 +23,7 @@ OTHER_FILES += \ $$PWD/data/tst_loadHtml.qml \ $$PWD/data/tst_loadProgress.qml \ $$PWD/data/tst_loadProgressSignal.qml \ + $$PWD/data/tst_loadRecursionCrash.qml \ $$PWD/data/tst_loadUrl.qml \ $$PWD/data/tst_navigationHistory.qml \ $$PWD/data/tst_navigationRequested.qml \ |