QtQuick TextEdit to set view property to QTextController
authorPekka Vuorela <pekka.ta.vuorela@nokia.com>
Wed, 7 Dec 2011 13:41:45 +0000 (15:41 +0200)
committerQt by Nokia <qt-info@nokia.com>
Mon, 12 Dec 2011 15:52:08 +0000 (16:52 +0100)
Controller wants to know on some cases where it's attached to.

Change-Id: I48df57ea1233a307f4d7424f0f944755604e3a6e
Reviewed-by: Lars Knoll <lars.knoll@nokia.com>
Reviewed-by: Joona Petrell <joona.t.petrell@nokia.com>
src/quick/items/qquicktextedit.cpp

index f1efbbe..91b0b0d 100644 (file)
@@ -1631,6 +1631,7 @@ void QQuickTextEditPrivate::init()
     document = new QQuickTextDocumentWithImageResources(q);
 
     control = new QQuickTextControl(document, q);
+    control->setView(q);
     control->setIgnoreUnusedNavigationEvents(true);
     control->setTextInteractionFlags(Qt::LinksAccessibleByMouse | Qt::TextSelectableByKeyboard | Qt::TextEditable);
     control->setDragEnabled(false);