From 4e012093462f07e7ffd42d4061539c54b4f43ace Mon Sep 17 00:00:00 2001 From: Simon Hausmann Date: Mon, 31 Mar 2014 16:49:14 +0200 Subject: Avoid recompiling of signal handlers defined in QtQuick state changes and Connection objects We can re-use the expression we've compiled at QML type compilation time, as long as we "inject" the signal parameters in the dynamic qml lookup chain. Change-Id: Icc417531c41dea06ff5d033011179af49b03f542 Reviewed-by: Lars Knoll --- tests/auto/qml/qqmlconnections/tst_qqmlconnections.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'tests/auto/qml/qqmlconnections/tst_qqmlconnections.cpp') diff --git a/tests/auto/qml/qqmlconnections/tst_qqmlconnections.cpp b/tests/auto/qml/qqmlconnections/tst_qqmlconnections.cpp index dbf48779d6..1cd1583f22 100644 --- a/tests/auto/qml/qqmlconnections/tst_qqmlconnections.cpp +++ b/tests/auto/qml/qqmlconnections/tst_qqmlconnections.cpp @@ -251,10 +251,9 @@ void tst_qqmlconnections::rewriteErrors() { QQmlEngine engine; QQmlComponent c(&engine, testFileUrl("rewriteError-unnamed.qml")); + QTest::ignoreMessage(QtWarningMsg, (c.url().toString() + ":5:35: QML Connections: Signal uses unnamed parameter followed by named parameter.").toLatin1()); TestObject *obj = qobject_cast(c.create()); QVERIFY(obj != 0); - - QTest::ignoreMessage(QtWarningMsg, (c.url().toString() + ":5:35: QML Connections: Signal uses unnamed parameter followed by named parameter.").toLatin1()); obj->unnamedArgumentSignal(1, .5, "hello"); QCOMPARE(obj->ran(), false); @@ -264,10 +263,10 @@ void tst_qqmlconnections::rewriteErrors() { QQmlEngine engine; QQmlComponent c(&engine, testFileUrl("rewriteError-global.qml")); + QTest::ignoreMessage(QtWarningMsg, (c.url().toString() + ":5:35: QML Connections: Signal parameter \"parseInt\" hides global variable.").toLatin1()); TestObject *obj = qobject_cast(c.create()); QVERIFY(obj != 0); - QTest::ignoreMessage(QtWarningMsg, (c.url().toString() + ":5:35: QML Connections: Signal parameter \"parseInt\" hides global variable.").toLatin1()); obj->signalWithGlobalName(10); QCOMPARE(obj->ran(), false); -- cgit v1.2.3