Stabilize and fix tst_qdeclarativetextedit.
authorFriedemann Kleint <Friedemann.Kleint@digia.com>
Wed, 24 Jul 2013 08:39:02 +0000 (10:39 +0200)
committerThe Qt Project <gerrit-noreply@qt-project.org>
Thu, 25 Jul 2013 12:22:06 +0000 (14:22 +0200)
commita77201b597b908097e6abc763d8ec275cf99774f
tree56aade97e6f2d19ab23f3de32166904462265b5f
parent019066a7153c6eb99caf58bac61fe5a5b7f76c67
Stabilize and fix tst_qdeclarativetextedit.

Introduce a scoped pointer for the views to ensure cleanup
after failing tests. Fix calculation in positionAt() to
use a QPaintDevice and the first line of the text.
Move calls to QDeclarativeView::setFocus() below activation
for it to set the "active" focus item correctly.

Task-number: QTBUG-32538
Change-Id: Ibf10d00b9bddd587f5721d5b5011f6eafc617f39
Reviewed-by: Jan Arve Sæther <jan-arve.saether@digia.com>
tests/auto/declarative/qdeclarativetextedit/tst_qdeclarativetextedit.cpp