summaryrefslogtreecommitdiffstats
path: root/tests/auto
diff options
context:
space:
mode:
authorTor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>2016-02-01 01:23:54 +0100
committerTor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>2016-02-02 02:12:26 +0000
commitd10bfff89ae103d84a2438d9b8bc6e55ba3b122d (patch)
tree48d7e57ba9dc01561e2ea5e4809b45674f2afae8 /tests/auto
parented2e15780385f7cf0a0d3aedc9cb2059d470bd58 (diff)
Revert "QWindow::destroy(): only reset QGuiApp::focus_window and friends as a last resort"
This reverts commit 4c71db756741d35ccb32dc4c32aa1823264c85df. It's too risky for 5.6, we should let it cook in dev for a while and backport when ready. Change-Id: I91e677e65d967f29c84a254cd3dffc8bb847b263 Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@theqtcompany.com>
Diffstat (limited to 'tests/auto')
-rw-r--r--tests/auto/gui/kernel/qwindow/tst_qwindow.cpp13
-rw-r--r--tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp3
2 files changed, 1 insertions, 15 deletions
diff --git a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
index 794d549b57..a89f0da4d2 100644
--- a/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
+++ b/tests/auto/gui/kernel/qwindow/tst_qwindow.cpp
@@ -94,7 +94,6 @@ private slots:
void modalWindowPosition();
void windowsTransientChildren();
void requestUpdate();
- void destroyResetsFocusWindow();
void initTestCase();
void stateChange_data();
void stateChange();
@@ -1805,18 +1804,6 @@ void tst_QWindow::requestUpdate()
QTRY_COMPARE(window.received(QEvent::UpdateRequest), 2);
}
-void tst_QWindow::destroyResetsFocusWindow()
-{
- QWindow window;
- window.showNormal();
- window.requestActivate();
- QVERIFY(QTest::qWaitForWindowActive(&window));
- QCOMPARE(qGuiApp->focusWindow(), &window);
-
- window.destroy();
- QVERIFY(!qGuiApp->focusWindow());
-}
-
#include <tst_qwindow.moc>
QTEST_MAIN(tst_QWindow)
diff --git a/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp b/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp
index bf17625803..b46609c371 100644
--- a/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp
+++ b/tests/auto/widgets/widgets/qlineedit/tst_qlineedit.cpp
@@ -3570,7 +3570,7 @@ void tst_QLineEdit::task174640_editingFinished()
QVERIFY(QTest::qWaitForWindowExposed(testMenu1));
QTest::qWait(20);
mw.activateWindow();
- qApp->processEvents();
+
delete testMenu1;
QCOMPARE(editingFinishedSpy.count(), 0);
QTRY_VERIFY(le1->hasFocus());
@@ -3582,7 +3582,6 @@ void tst_QLineEdit::task174640_editingFinished()
QVERIFY(QTest::qWaitForWindowExposed(testMenu2));
QTest::qWait(20);
mw.activateWindow();
- qApp->processEvents();
delete testMenu2;
QCOMPARE(editingFinishedSpy.count(), 1);
}