summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/declarative/debugger/qmldebug.cpp10
-rw-r--r--src/declarative/debugger/qmldebug_p.h4
-rw-r--r--src/declarative/graphicsitems/qmlgraphicspainteditem.cpp20
-rw-r--r--src/gui/graphicsview/qgraphicsview.cpp3
-rw-r--r--tests/auto/declarative/debugger/debuggerutil.cpp17
-rw-r--r--tests/auto/declarative/debugger/debuggerutil_p.h10
-rw-r--r--tests/auto/declarative/debugger/qmldebug/qmldebug.pro4
-rw-r--r--tests/auto/declarative/debugger/qmldebug/tst_qmldebug.cpp149
-rw-r--r--tests/auto/declarative/debugger/qmldebugclient/tst_qmldebugclient.cpp8
-rw-r--r--tests/auto/declarative/debugger/qmldebugservice/tst_qmldebugservice.cpp12
-rw-r--r--tests/auto/declarative/declarative.pro9
-rw-r--r--tools/qmldebugger/creatorplugin/qmlinspectormode.cpp4
-rw-r--r--tools/qmldebugger/standalone/engine.cpp4
-rw-r--r--tools/qmldebugger/standalone/expressionquerywidget.cpp2
-rw-r--r--tools/qmldebugger/standalone/objectpropertiesview.cpp4
-rw-r--r--tools/qmldebugger/standalone/objecttree.cpp2
-rw-r--r--tools/qmldebugger/standalone/watchtable.cpp2
17 files changed, 158 insertions, 106 deletions
diff --git a/src/declarative/debugger/qmldebug.cpp b/src/declarative/debugger/qmldebug.cpp
index f24b456..72f613a 100644
--- a/src/declarative/debugger/qmldebug.cpp
+++ b/src/declarative/debugger/qmldebug.cpp
@@ -331,7 +331,7 @@ void QmlEngineDebugPrivate::message(const QByteArray &data)
QVariant value;
ds >> queryId >> debugId >> name >> value;
- QmlDebugWatch *watch = watched.value(queryId);
+ QmlDebugWatch *watch = watched.value(queryId, 0);
if (!watch)
return;
emit watch->valueChanged(name, value);
@@ -428,13 +428,15 @@ void QmlEngineDebug::removeWatch(QmlDebugWatch *watch)
{
Q_D(QmlEngineDebug);
- if (!watch || watch->state() == QmlDebugWatch::Inactive || watch->state() == QmlDebugWatch::Dead)
+ if (!watch || !watch->m_client)
return;
+ watch->m_client = 0;
watch->setState(QmlDebugWatch::Inactive);
+
d->watched.remove(watch->queryId());
- if (d->client->isConnected()) {
+ if (d->client && d->client->isConnected()) {
QByteArray message;
QDataStream ds(&message, QIODevice::WriteOnly);
ds << QByteArray("NO_WATCH") << watch->queryId();
@@ -562,8 +564,6 @@ QmlDebugWatch::QmlDebugWatch(QObject *parent)
QmlDebugWatch::~QmlDebugWatch()
{
- if (m_client)
- m_client->removeWatch(this);
}
int QmlDebugWatch::queryId() const
diff --git a/src/declarative/debugger/qmldebug_p.h b/src/declarative/debugger/qmldebug_p.h
index 4bc54e8..cd2adf6 100644
--- a/src/declarative/debugger/qmldebug_p.h
+++ b/src/declarative/debugger/qmldebug_p.h
@@ -113,7 +113,7 @@ public:
State state() const;
Q_SIGNALS:
- void stateChanged(State);
+ void stateChanged(QmlDebugWatch::State);
//void objectChanged(int, const QmlDebugObjectReference &);
//void valueChanged(int, const QVariant &);
@@ -170,7 +170,7 @@ public:
// bool waitUntilCompleted();
Q_SIGNALS:
- void stateChanged(State);
+ void stateChanged(QmlDebugQuery::State);
protected:
QmlDebugQuery(QObject *);
diff --git a/src/declarative/graphicsitems/qmlgraphicspainteditem.cpp b/src/declarative/graphicsitems/qmlgraphicspainteditem.cpp
index 2c849c8..b1b1210 100644
--- a/src/declarative/graphicsitems/qmlgraphicspainteditem.cpp
+++ b/src/declarative/graphicsitems/qmlgraphicspainteditem.cpp
@@ -49,6 +49,7 @@
#include <QApplication>
#include <QGraphicsSceneMouseEvent>
#include <QPainter>
+#include <QPaintEngine>
QT_BEGIN_NAMESPACE
@@ -209,9 +210,24 @@ void QmlGraphicsPaintedItem::paint(QPainter *p, const QStyleOptionGraphicsItem *
++inpaint;
- const QRect clip = p->clipRegion().boundingRect();
+ const QTransform &x = p->deviceTransform();
+ QTransform xinv = x.inverted();
+ QRegion effectiveClip;
+ QRegion sysClip = p->paintEngine()->systemClip();
+ if (xinv.type() <= QTransform::TxScale && sysClip.numRects() < 5) {
+ // simple transform, region gets no more complicated...
+ effectiveClip = xinv.map(sysClip);
+ } else {
+ // do not make complicated regions...
+ effectiveClip = xinv.mapRect(sysClip.boundingRect());
+ }
+
+ QRegion topaint = p->clipRegion();
+ if (topaint.isEmpty())
+ topaint = effectiveClip;
+ else
+ topaint &= effectiveClip;
- QRegion topaint(clip);
topaint &= content;
QRegion uncached(content);
p->setRenderHints(QPainter::SmoothPixmapTransform, d->smooth);
diff --git a/src/gui/graphicsview/qgraphicsview.cpp b/src/gui/graphicsview/qgraphicsview.cpp
index 87585a2..90c0ff2 100644
--- a/src/gui/graphicsview/qgraphicsview.cpp
+++ b/src/gui/graphicsview/qgraphicsview.cpp
@@ -3275,13 +3275,10 @@ void QGraphicsView::paintEvent(QPaintEvent *event)
// Determine the exposed region
d->exposedRegion = event->region();
- if (d->exposedRegion.isEmpty())
- d->exposedRegion = viewport()->rect();
QRectF exposedSceneRect = mapToScene(d->exposedRegion.boundingRect()).boundingRect();
// Set up the painter
QPainter painter(viewport());
- painter.setClipRect(event->rect(), Qt::IntersectClip);
#ifndef QT_NO_RUBBERBAND
if (d->rubberBanding && !d->rubberBandRect.isEmpty())
painter.save();
diff --git a/tests/auto/declarative/debugger/debuggerutil.cpp b/tests/auto/declarative/debugger/debuggerutil.cpp
index 8e93407..761105e 100644
--- a/tests/auto/declarative/debugger/debuggerutil.cpp
+++ b/tests/auto/declarative/debugger/debuggerutil.cpp
@@ -49,41 +49,42 @@
namespace QmlDebuggerTest {
- void waitForSignal(QObject *receiver, const char *member) {
+ bool waitForSignal(QObject *receiver, const char *member, int timeout) {
QEventLoop loop;
QTimer timer;
QObject::connect(&timer, SIGNAL(timeout()), &loop, SLOT(quit()));
QObject::connect(receiver, member, &loop, SLOT(quit()));
- timer.start(5000);
+ timer.start(timeout);
loop.exec();
+ return timer.isActive();
}
}
-EchoService::EchoService(const QString &s, QObject *parent)
+QmlDebuggerTestService::QmlDebuggerTestService(const QString &s, QObject *parent)
: QmlDebugService(s, parent), enabled(false)
{
}
-void EchoService::messageReceived(const QByteArray &ba)
+void QmlDebuggerTestService::messageReceived(const QByteArray &ba)
{
sendMessage(ba);
}
-void EchoService::enabledChanged(bool e)
+void QmlDebuggerTestService::enabledChanged(bool e)
{
emit enabledStateChanged();
enabled = e;
}
-MyQmlDebugClient::MyQmlDebugClient(const QString &s, QmlDebugConnection *c)
+QmlDebuggerTestClient::QmlDebuggerTestClient(const QString &s, QmlDebugConnection *c)
: QmlDebugClient(s, c)
{
}
-QByteArray MyQmlDebugClient::waitForResponse()
+QByteArray QmlDebuggerTestClient::waitForResponse()
{
QSignalSpy spy(this, SIGNAL(serverMessage(QByteArray)));
QmlDebuggerTest::waitForSignal(this, SIGNAL(serverMessage(QByteArray)));
@@ -94,7 +95,7 @@ QByteArray MyQmlDebugClient::waitForResponse()
return spy.at(0).at(0).value<QByteArray>();
}
-void MyQmlDebugClient::messageReceived(const QByteArray &ba)
+void QmlDebuggerTestClient::messageReceived(const QByteArray &ba)
{
emit serverMessage(ba);
}
diff --git a/tests/auto/declarative/debugger/debuggerutil_p.h b/tests/auto/declarative/debugger/debuggerutil_p.h
index 155d550..5e27a7a 100644
--- a/tests/auto/declarative/debugger/debuggerutil_p.h
+++ b/tests/auto/declarative/debugger/debuggerutil_p.h
@@ -47,14 +47,14 @@
namespace QmlDebuggerTest {
- void waitForSignal(QObject *receiver, const char *member);
+ bool waitForSignal(QObject *receiver, const char *member, int timeout = 5000);
}
-class EchoService : public QmlDebugService
+class QmlDebuggerTestService : public QmlDebugService
{
Q_OBJECT
public:
- EchoService(const QString &s, QObject *parent = 0);
+ QmlDebuggerTestService(const QString &s, QObject *parent = 0);
bool enabled;
signals:
@@ -66,11 +66,11 @@ protected:
virtual void enabledChanged(bool e);
};
-class MyQmlDebugClient : public QmlDebugClient
+class QmlDebuggerTestClient : public QmlDebugClient
{
Q_OBJECT
public:
- MyQmlDebugClient(const QString &s, QmlDebugConnection *c);
+ QmlDebuggerTestClient(const QString &s, QmlDebugConnection *c);
QByteArray waitForResponse();
diff --git a/tests/auto/declarative/debugger/qmldebug/qmldebug.pro b/tests/auto/declarative/debugger/qmldebug/qmldebug.pro
index 61f821e..c1ac125 100644
--- a/tests/auto/declarative/debugger/qmldebug/qmldebug.pro
+++ b/tests/auto/declarative/debugger/qmldebug/qmldebug.pro
@@ -2,4 +2,6 @@ load(qttest_p4)
contains(QT_CONFIG,declarative): QT += network declarative
macx:CONFIG -= app_bundle
-SOURCES += tst_qmldebug.cpp
+HEADERS += ../debuggerutil_p.h
+SOURCES += tst_qmldebug.cpp \
+ ../debuggerutil.cpp
diff --git a/tests/auto/declarative/debugger/qmldebug/tst_qmldebug.cpp b/tests/auto/declarative/debugger/qmldebug/tst_qmldebug.cpp
index 7c52a19..bfb8aee 100644
--- a/tests/auto/declarative/debugger/qmldebug/tst_qmldebug.cpp
+++ b/tests/auto/declarative/debugger/qmldebug/tst_qmldebug.cpp
@@ -59,6 +59,10 @@
#include <private/qmldebugservice_p.h>
#include <private/qmlgraphicsrectangle_p.h>
+#include "../debuggerutil_p.h"
+
+Q_DECLARE_METATYPE(QmlDebugWatch::State)
+
class tst_QmlDebug : public QObject
{
@@ -68,12 +72,6 @@ public:
tst_QmlDebug(QmlDebugConnection *conn, QmlEngine *engine, QmlGraphicsItem *rootItem)
: m_conn(conn), m_dbg(0), m_engine(engine), m_rootItem(rootItem) {}
-protected slots:
- void saveValueChange(const QByteArray &ba, const QVariant &v)
- {
- m_savedValueChanges[ba] = v;
- }
-
private:
QmlDebugObjectReference findRootObject();
QmlDebugPropertyReference findProperty(const QList<QmlDebugPropertyReference> &props, const QString &name) const;
@@ -90,7 +88,6 @@ private:
QmlEngineDebug *m_dbg;
QmlEngine *m_engine;
QmlGraphicsItem *m_rootItem;
- QHash<QByteArray, QVariant> m_savedValueChanges;
private slots:
void initTestCase();
@@ -99,6 +96,8 @@ private slots:
void watch_object();
void watch_expression();
void watch_expression_data();
+ void watch_context();
+ void watch_file();
void queryAvailableEngines();
void queryRootContexts();
@@ -160,14 +159,8 @@ void tst_QmlDebug::waitForQuery(QmlDebugQuery *query)
{
QVERIFY(query);
QCOMPARE(query->parent(), this);
- QEventLoop loop;
- QTimer timer;
QVERIFY(query->state() == QmlDebugQuery::Waiting);
- connect(query, SIGNAL(stateChanged(State)), &loop, SLOT(quit()));
- connect(&timer, SIGNAL(timeout()), &loop, SLOT(quit()));
- timer.start(5000);
- loop.exec();
- if (!timer.isActive())
+ if (!QmlDebuggerTest::waitForSignal(query, SIGNAL(stateChanged(QmlDebugQuery::State))))
QFAIL("query timed out");
}
@@ -269,6 +262,8 @@ void tst_QmlDebug::compareProperties(const QmlDebugPropertyReference &a, const Q
void tst_QmlDebug::initTestCase()
{
m_dbg = new QmlEngineDebug(m_conn, this);
+
+ qRegisterMetaType<QmlDebugWatch::State>();
}
void tst_QmlDebug::watch_property()
@@ -276,29 +271,31 @@ void tst_QmlDebug::watch_property()
QmlDebugObjectReference obj = findRootObject();
QmlDebugPropertyReference prop = findProperty(obj.properties(), "width");
- QmlDebugPropertyWatch *watch = m_dbg->addWatch(prop, this);
+ QmlDebugPropertyWatch *watch;
+
+ QmlEngineDebug unconnected(0);
+ watch = unconnected.addWatch(prop, this);
+ QCOMPARE(watch->state(), QmlDebugWatch::Dead);
+ delete watch;
+
+ watch = m_dbg->addWatch(prop, this);
QCOMPARE(watch->state(), QmlDebugWatch::Waiting);
QCOMPARE(watch->objectDebugId(), obj.debugId());
QCOMPARE(watch->name(), prop.name());
QSignalSpy spy(watch, SIGNAL(valueChanged(QByteArray,QVariant)));
- QEventLoop loop;
- QTimer timer;
- connect(watch, SIGNAL(valueChanged(QByteArray,QVariant)), &loop, SLOT(quit()));
- connect(&timer, SIGNAL(timeout()), &loop, SLOT(quit()));
int origWidth = m_rootItem->property("width").toInt();
- timer.start(5000);
m_rootItem->setProperty("width", origWidth*2);
- loop.exec();
- if (!timer.isActive())
- QFAIL("Did not receive valueChanged() for property");
+ // stateChanged() is received before valueChanged()
+ QVERIFY(QmlDebuggerTest::waitForSignal(watch, SIGNAL(stateChanged(QmlDebugWatch::State))));
+ QCOMPARE(spy.count(), 1);
m_dbg->removeWatch(watch);
delete watch;
- // restore original value and verify spy doesn't get a signal since watch has been removed
+ // restore original value and verify spy doesn't get additional signal since watch has been removed
m_rootItem->setProperty("width", origWidth);
QTest::qWait(100);
QCOMPARE(spy.count(), 1);
@@ -324,48 +321,51 @@ void tst_QmlDebug::watch_object()
delete q_context;
delete q_obj;
- QmlDebugWatch *watch = m_dbg->addWatch(obj, this);
+ QmlDebugWatch *watch;
+
+ QmlEngineDebug unconnected(0);
+ watch = unconnected.addWatch(obj, this);
+ QCOMPARE(watch->state(), QmlDebugWatch::Dead);
+ delete watch;
+
+ watch = m_dbg->addWatch(obj, this);
QCOMPARE(watch->state(), QmlDebugWatch::Waiting);
QCOMPARE(watch->objectDebugId(), obj.debugId());
- m_savedValueChanges.clear();
- connect(watch, SIGNAL(valueChanged(QByteArray,QVariant)),
- SLOT(saveValueChange(QByteArray,QVariant)));
+ QSignalSpy spy(watch, SIGNAL(valueChanged(QByteArray,QVariant)));
int origWidth = m_rootItem->property("width").toInt();
int origHeight = m_rootItem->property("height").toInt();
m_rootItem->setProperty("width", origWidth*2);
m_rootItem->setProperty("height", origHeight*2);
- QEventLoop loop;
- QTimer timer;
- timer.start(5000);
- while (timer.isActive() &&
- (!m_savedValueChanges.contains("width") || !m_savedValueChanges.contains("height"))) {
- loop.processEvents(QEventLoop::AllEvents, 50);
- }
+ // stateChanged() is received before any valueChanged() signals
+ QVERIFY(QmlDebuggerTest::waitForSignal(watch, SIGNAL(stateChanged(QmlDebugWatch::State))));
+ QVERIFY(spy.count() > 0);
- QVariant newWidth = m_savedValueChanges["width"];
- QVariant newHeight = m_savedValueChanges["height"];
+ int newWidth = -1;
+ int newHeight = -1;
+ for (int i=0; i<spy.count(); i++) {
+ const QVariantList &values = spy[i];
+ if (values[0].value<QByteArray>() == "width")
+ newWidth = values[1].value<QVariant>().toInt();
+ else if (values[0].value<QByteArray>() == "height")
+ newHeight = values[1].value<QVariant>().toInt();
+
+ }
m_dbg->removeWatch(watch);
delete watch;
// since watch has been removed, restoring the original values should not trigger a valueChanged()
- m_savedValueChanges.clear();
+ spy.clear();
m_rootItem->setProperty("width", origWidth);
m_rootItem->setProperty("height", origHeight);
QTest::qWait(100);
- QCOMPARE(m_savedValueChanges.count(), 0);
+ QCOMPARE(spy.count(), 0);
- if (newWidth.isNull() || newHeight.isNull()) {
- QString s = QString("Did not receive both width and height changes (width=%1, height=%2)")
- .arg(newWidth.toString()).arg(newHeight.toString());
- QFAIL(qPrintable(s));
- }
-
- QCOMPARE(newWidth, qVariantFromValue(origWidth*2));
- QCOMPARE(newHeight, qVariantFromValue(origHeight*2));
+ QCOMPARE(newWidth, origWidth * 2);
+ QCOMPARE(newHeight, origHeight * 2);
}
void tst_QmlDebug::watch_expression()
@@ -378,30 +378,37 @@ void tst_QmlDebug::watch_expression()
QmlDebugObjectReference obj = findRootObject();
- QmlDebugObjectExpressionWatch *watch = m_dbg->addWatch(obj, expr, this);
+ QmlDebugObjectExpressionWatch *watch;
+
+ QmlEngineDebug unconnected(0);
+ watch = unconnected.addWatch(obj, expr, this);
+ QCOMPARE(watch->state(), QmlDebugWatch::Dead);
+ delete watch;
+
+ watch = m_dbg->addWatch(obj, expr, this);
QCOMPARE(watch->state(), QmlDebugWatch::Waiting);
QCOMPARE(watch->objectDebugId(), obj.debugId());
QCOMPARE(watch->expression(), expr);
+ QSignalSpy spyState(watch, SIGNAL(stateChanged(QmlDebugWatch::State)));
+
QSignalSpy spy(watch, SIGNAL(valueChanged(QByteArray,QVariant)));
int expectedSpyCount = incrementCount + 1; // should also get signal with expression's initial value
int width = origWidth;
for (int i=0; i<incrementCount+1; i++) {
- QTimer timer;
- timer.start(5000);
if (i > 0) {
width += increment;
m_rootItem->setProperty("width", width);
}
- QEventLoop loop;
- connect(&timer, SIGNAL(timeout()), &loop, SLOT(quit()));
- connect(watch, SIGNAL(valueChanged(QByteArray,QVariant)), &loop, SLOT(quit()));
- loop.exec();
- if (!timer.isActive())
- QFAIL("Did not receive valueChanged() signal for expression");
+ if (!QmlDebuggerTest::waitForSignal(watch, SIGNAL(valueChanged(QByteArray,QVariant))))
+ QFAIL("Did not receive valueChanged() for expression");
}
+ if (spyState.count() == 0)
+ QVERIFY(QmlDebuggerTest::waitForSignal(watch, SIGNAL(stateChanged(QmlDebugWatch::State))));
+ QCOMPARE(spyState.count(), 1);
+
m_dbg->removeWatch(watch);
delete watch;
@@ -427,6 +434,20 @@ void tst_QmlDebug::watch_expression_data()
QTest::newRow("width+10") << "width + 10" << 10 << 5;
}
+void tst_QmlDebug::watch_context()
+{
+ QmlDebugContextReference c;
+ QTest::ignoreMessage(QtWarningMsg, "QmlEngineDebug::addWatch(): Not implemented");
+ QVERIFY(!m_dbg->addWatch(c, QString(), this));
+}
+
+void tst_QmlDebug::watch_file()
+{
+ QmlDebugFileReference f;
+ QTest::ignoreMessage(QtWarningMsg, "QmlEngineDebug::addWatch(): Not implemented");
+ QVERIFY(!m_dbg->addWatch(f, this));
+}
+
void tst_QmlDebug::queryAvailableEngines()
{
QmlDebugEnginesQuery *q_engines;
@@ -722,6 +743,20 @@ void tst_QmlDebug::tst_QmlDebugPropertyReference()
waitForQuery(query);
QmlDebugObjectReference obj = query->object();
delete query;
+
+ QmlDebugPropertyReference ref = findProperty(obj.properties(), "scale");
+ QVERIFY(ref.objectDebugId() > 0);
+ QVERIFY(!ref.name().isEmpty());
+ QVERIFY(!ref.value().isNull());
+ QVERIFY(!ref.valueTypeName().isEmpty());
+ QVERIFY(!ref.binding().isEmpty());
+ QVERIFY(ref.hasNotifySignal());
+
+ QmlDebugPropertyReference copy(ref);
+ QmlDebugPropertyReference copyAssign;
+ copyAssign = ref;
+ foreach (const QmlDebugPropertyReference &r, (QList<QmlDebugPropertyReference>() << copy << copyAssign))
+ compareProperties(r, ref);
}
class TestRunnerThread : public QThread
@@ -771,7 +806,7 @@ int main(int argc, char *argv[])
QmlComponent component(&engine,
"import Qt 4.6\n"
"Item {\n"
- "width: 10; height: 20;\n"
+ "width: 10; height: 20; scale: blueRect.scale;\n"
"Rectangle { id: blueRect; width: 500; height: 600; color: \"blue\"; }"
"Text { color: blueRect.color; }"
"}\n",
diff --git a/tests/auto/declarative/debugger/qmldebugclient/tst_qmldebugclient.cpp b/tests/auto/declarative/debugger/qmldebugclient/tst_qmldebugclient.cpp
index db33061..0a768a5 100644
--- a/tests/auto/declarative/debugger/qmldebugclient/tst_qmldebugclient.cpp
+++ b/tests/auto/declarative/debugger/qmldebugclient/tst_qmldebugclient.cpp
@@ -89,8 +89,8 @@ void tst_QmlDebugClient::isEnabled()
void tst_QmlDebugClient::setEnabled()
{
- EchoService service("tst_QmlDebugClient::setEnabled()");
- MyQmlDebugClient client("tst_QmlDebugClient::setEnabled()", m_conn);
+ QmlDebuggerTestService service("tst_QmlDebugClient::setEnabled()");
+ QmlDebuggerTestClient client("tst_QmlDebugClient::setEnabled()", m_conn);
QCOMPARE(service.isEnabled(), false);
@@ -125,8 +125,8 @@ void tst_QmlDebugClient::isConnected()
void tst_QmlDebugClient::sendMessage()
{
- EchoService service("tst_QmlDebugClient::sendMessage()");
- MyQmlDebugClient client("tst_QmlDebugClient::sendMessage()", m_conn);
+ QmlDebuggerTestService service("tst_QmlDebugClient::sendMessage()");
+ QmlDebuggerTestClient client("tst_QmlDebugClient::sendMessage()", m_conn);
QByteArray msg = "hello!";
diff --git a/tests/auto/declarative/debugger/qmldebugservice/tst_qmldebugservice.cpp b/tests/auto/declarative/debugger/qmldebugservice/tst_qmldebugservice.cpp
index 224e7e1..2cd8607 100644
--- a/tests/auto/declarative/debugger/qmldebugservice/tst_qmldebugservice.cpp
+++ b/tests/auto/declarative/debugger/qmldebugservice/tst_qmldebugservice.cpp
@@ -85,10 +85,10 @@ void tst_QmlDebugService::name()
void tst_QmlDebugService::isEnabled()
{
- EchoService service("tst_QmlDebugService::isEnabled()", m_conn);
+ QmlDebuggerTestService service("tst_QmlDebugService::isEnabled()", m_conn);
QCOMPARE(service.isEnabled(), false);
- MyQmlDebugClient client("tst_QmlDebugService::isEnabled()", m_conn);
+ QmlDebuggerTestClient client("tst_QmlDebugService::isEnabled()", m_conn);
client.setEnabled(true);
QmlDebuggerTest::waitForSignal(&service, SIGNAL(enabledStateChanged()));
QCOMPARE(service.isEnabled(), true);
@@ -100,8 +100,8 @@ void tst_QmlDebugService::isEnabled()
void tst_QmlDebugService::enabledChanged()
{
- EchoService service("tst_QmlDebugService::enabledChanged()");
- MyQmlDebugClient client("tst_QmlDebugService::enabledChanged()", m_conn);
+ QmlDebuggerTestService service("tst_QmlDebugService::enabledChanged()");
+ QmlDebuggerTestClient client("tst_QmlDebugService::enabledChanged()", m_conn);
QCOMPARE(service.enabled, false);
@@ -112,8 +112,8 @@ void tst_QmlDebugService::enabledChanged()
void tst_QmlDebugService::sendMessage()
{
- EchoService service("tst_QmlDebugService::sendMessage()");
- MyQmlDebugClient client("tst_QmlDebugService::sendMessage()", m_conn);
+ QmlDebuggerTestService service("tst_QmlDebugService::sendMessage()");
+ QmlDebuggerTestClient client("tst_QmlDebugService::sendMessage()", m_conn);
QByteArray msg = "hello!";
diff --git a/tests/auto/declarative/declarative.pro b/tests/auto/declarative/declarative.pro
index 6b2e39e..8a3a06c 100644
--- a/tests/auto/declarative/declarative.pro
+++ b/tests/auto/declarative/declarative.pro
@@ -8,12 +8,9 @@ SUBDIRS += \
debugger \ # Cover
examples \
layouts \ # Cover
- qmlgraphicslistview \ # Cover
- qmlgraphicsgridview \ # Cover
numberformatter \ # Cover
parserstress \ # Cover
pathview \ # Cover
- qmlgraphicsloader \ # Cover
qmetaobjectbuilder \ # Cover
qmlbinding \ # Cover
qmlconnection \ # Cover
@@ -22,10 +19,13 @@ SUBDIRS += \
qmlecmascript \ # Cover
qmlerror \ # Cover
qmlfontloader \ # Cover
- qmlgraphicsitem \ # Cover
qmlgraphicsborderimage \ # Cover
qmlgraphicsflickable \ # Cover
qmlgraphicsflipable \ # Cover
+ qmlgraphicsgridview \ # Cover
+ qmlgraphicsitem \ # Cover
+ qmlgraphicslistview \ # Cover
+ qmlgraphicsloader \ # Cover
qmlgraphicsparticles \ # Cover
qmlgraphicspositioners \ # Cover
qmlgraphicstext \ # Cover
@@ -36,6 +36,7 @@ SUBDIRS += \
qmllanguage \ # Cover
qmllist \ # Cover
qmllistaccessor \ # Cover
+ qmllistmodel \ # Cover
qmlmetaproperty \ # Cover
qmlmetatype \ # Cover
qmlpixmapcache \ # Cover
diff --git a/tools/qmldebugger/creatorplugin/qmlinspectormode.cpp b/tools/qmldebugger/creatorplugin/qmlinspectormode.cpp
index ce8ef30..aa7d292 100644
--- a/tools/qmldebugger/creatorplugin/qmlinspectormode.cpp
+++ b/tools/qmldebugger/creatorplugin/qmlinspectormode.cpp
@@ -489,7 +489,7 @@ void QmlInspectorMode::reloadEngines()
if (!m_engineQuery->isWaiting())
enginesChanged();
else
- QObject::connect(m_engineQuery, SIGNAL(stateChanged(State)),
+ QObject::connect(m_engineQuery, SIGNAL(stateChanged(QmlDebugQuery::State)),
this, SLOT(enginesChanged()));
}
@@ -528,7 +528,7 @@ void QmlInspectorMode::queryEngineContext(int id)
if (!m_contextQuery->isWaiting())
contextChanged();
else
- QObject::connect(m_contextQuery, SIGNAL(stateChanged(State)),
+ QObject::connect(m_contextQuery, SIGNAL(stateChanged(QmlDebugQuery::State)),
this, SLOT(contextChanged()));
}
diff --git a/tools/qmldebugger/standalone/engine.cpp b/tools/qmldebugger/standalone/engine.cpp
index d438518..6cfd82b 100644
--- a/tools/qmldebugger/standalone/engine.cpp
+++ b/tools/qmldebugger/standalone/engine.cpp
@@ -163,7 +163,7 @@ void EnginePane::queryContext(int id)
if (!m_context->isWaiting())
contextChanged();
else
- QObject::connect(m_context, SIGNAL(stateChanged(State)),
+ QObject::connect(m_context, SIGNAL(stateChanged(QmlDebugQuery::State)),
this, SLOT(contextChanged()));
}
@@ -186,7 +186,7 @@ void EnginePane::refreshEngines()
if (!m_engines->isWaiting())
enginesChanged();
else
- QObject::connect(m_engines, SIGNAL(stateChanged(State)),
+ QObject::connect(m_engines, SIGNAL(stateChanged(QmlDebugQuery::State)),
this, SLOT(enginesChanged()));
}
diff --git a/tools/qmldebugger/standalone/expressionquerywidget.cpp b/tools/qmldebugger/standalone/expressionquerywidget.cpp
index 5b7bc8f..cd59871 100644
--- a/tools/qmldebugger/standalone/expressionquerywidget.cpp
+++ b/tools/qmldebugger/standalone/expressionquerywidget.cpp
@@ -173,7 +173,7 @@ void ExpressionQueryWidget::executeExpression()
if (!m_query->isWaiting())
showResult();
else
- QObject::connect(m_query, SIGNAL(stateChanged(State)),
+ QObject::connect(m_query, SIGNAL(stateChanged(QmlDebugQuery::State)),
this, SLOT(showResult()));
m_lastExpr = m_expr;
diff --git a/tools/qmldebugger/standalone/objectpropertiesview.cpp b/tools/qmldebugger/standalone/objectpropertiesview.cpp
index abfb7a5..3a8d8c8 100644
--- a/tools/qmldebugger/standalone/objectpropertiesview.cpp
+++ b/tools/qmldebugger/standalone/objectpropertiesview.cpp
@@ -124,7 +124,7 @@ void ObjectPropertiesView::reload(const QmlDebugObjectReference &obj)
if (!m_query->isWaiting())
queryFinished();
else
- QObject::connect(m_query, SIGNAL(stateChanged(State)),
+ QObject::connect(m_query, SIGNAL(stateChanged(QmlDebugQuery::State)),
this, SLOT(queryFinished()));
}
@@ -223,7 +223,7 @@ void ObjectPropertiesView::watchCreated(QmlDebugWatch *watch)
{
if (watch->objectDebugId() == m_object.debugId()
&& qobject_cast<QmlDebugPropertyWatch*>(watch)) {
- connect(watch, SIGNAL(stateChanged(State)), SLOT(watchStateChanged()));
+ connect(watch, SIGNAL(stateChanged(QmlDebugWatch::State)), SLOT(watchStateChanged()));
setWatched(qobject_cast<QmlDebugPropertyWatch*>(watch)->name(), true);
}
}
diff --git a/tools/qmldebugger/standalone/objecttree.cpp b/tools/qmldebugger/standalone/objecttree.cpp
index 4dbc1a7..cf467f2 100644
--- a/tools/qmldebugger/standalone/objecttree.cpp
+++ b/tools/qmldebugger/standalone/objecttree.cpp
@@ -86,7 +86,7 @@ void ObjectTree::reload(int objectDebugId)
if (!m_query->isWaiting())
objectFetched();
else
- QObject::connect(m_query, SIGNAL(stateChanged(State)),
+ QObject::connect(m_query, SIGNAL(stateChanged(QmlDebugQuery::State)),
this, SLOT(objectFetched()));
}
diff --git a/tools/qmldebugger/standalone/watchtable.cpp b/tools/qmldebugger/standalone/watchtable.cpp
index 47c1c88..0e73de5 100644
--- a/tools/qmldebugger/standalone/watchtable.cpp
+++ b/tools/qmldebugger/standalone/watchtable.cpp
@@ -77,7 +77,7 @@ void WatchTableModel::addWatch(QmlDebugWatch *watch, const QString &title)
connect(watch, SIGNAL(valueChanged(QByteArray,QVariant)),
SLOT(watchedValueChanged(QByteArray,QVariant)));
- connect(watch, SIGNAL(stateChanged(State)), SLOT(watchStateChanged()));
+ connect(watch, SIGNAL(stateChanged(QmlDebugWatch::State)), SLOT(watchStateChanged()));
int col = columnCount(QModelIndex());
beginInsertColumns(QModelIndex(), col, col);