diff options
author | Liang Qi <liang.qi@theqtcompany.com> | 2015-10-14 19:52:20 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@theqtcompany.com> | 2015-10-14 19:52:20 +0200 |
commit | 62ad5cf27a194a09404bab09bdcaa75273055168 (patch) | |
tree | 4c5c12f8a4e4ae598d5dfd89c8a67472537ead9e /src/webchannel | |
parent | 2eb448ab7c0d84db3243ecc1ce09db333e11cdda (diff) | |
parent | 459a6ad0ae963b30c484a14b8cb910a29e1b1dcb (diff) | |
download | qtwebchannel-62ad5cf27a194a09404bab09bdcaa75273055168.tar.gz |
Merge remote-tracking branch 'origin/5.6' into dev
Change-Id: I0b933efe65501476b0004afd6f7c36672baa897c
Diffstat (limited to 'src/webchannel')
-rw-r--r-- | src/webchannel/qmetaobjectpublisher.cpp | 4 | ||||
-rw-r--r-- | src/webchannel/qwebchannel.h | 4 | ||||
-rw-r--r-- | src/webchannel/qwebchannelabstracttransport.h | 2 | ||||
-rw-r--r-- | src/webchannel/webchannel.pro | 4 |
4 files changed, 7 insertions, 7 deletions
diff --git a/src/webchannel/qmetaobjectpublisher.cpp b/src/webchannel/qmetaobjectpublisher.cpp index 61c5144..324191e 100644 --- a/src/webchannel/qmetaobjectpublisher.cpp +++ b/src/webchannel/qmetaobjectpublisher.cpp @@ -41,7 +41,7 @@ #include <QDebug> #include <QJsonObject> #include <QJsonArray> -#ifdef QT_HAVE_QML +#ifndef QT_NO_JSVALUE #include <QJSValue> #endif #include <QUuid> @@ -491,7 +491,7 @@ QJsonValue QMetaObjectPublisher::wrapResult(const QVariant &result, QWebChannelA objectInfo[KEY_DATA] = classInfo; return objectInfo; -#ifdef QT_HAVE_QML +#ifndef QT_NO_JSVALUE } else if (result.canConvert<QJSValue>()) { // Workaround for keeping QJSValues from QVariant. // Calling QJSValue::toVariant() converts JS-objects/arrays to QVariantMap/List diff --git a/src/webchannel/qwebchannel.h b/src/webchannel/qwebchannel.h index 0e642db..d32d017 100644 --- a/src/webchannel/qwebchannel.h +++ b/src/webchannel/qwebchannel.h @@ -35,8 +35,8 @@ #ifndef QWEBCHANNEL_H #define QWEBCHANNEL_H -#include <QObject> -#include <QJsonValue> +#include <QtCore/QObject> +#include <QtCore/QJsonValue> #include <QtWebChannel/qwebchannelglobal.h> diff --git a/src/webchannel/qwebchannelabstracttransport.h b/src/webchannel/qwebchannelabstracttransport.h index 851c622..e7f2af4 100644 --- a/src/webchannel/qwebchannelabstracttransport.h +++ b/src/webchannel/qwebchannelabstracttransport.h @@ -34,7 +34,7 @@ #ifndef QWEBCHANNELABSTRACTTRANSPORT_H #define QWEBCHANNELABSTRACTTRANSPORT_H -#include <QObject> +#include <QtCore/QObject> #include <QtWebChannel/qwebchannelglobal.h> QT_BEGIN_NAMESPACE diff --git a/src/webchannel/webchannel.pro b/src/webchannel/webchannel.pro index edaac13..931ee03 100644 --- a/src/webchannel/webchannel.pro +++ b/src/webchannel/webchannel.pro @@ -30,8 +30,6 @@ SOURCES += \ qtHaveModule(qml) { QT += qml - DEFINES += "QT_HAVE_QML" - SOURCES += \ qqmlwebchannel.cpp \ qqmlwebchannelattached.cpp @@ -41,6 +39,8 @@ qtHaveModule(qml) { PRIVATE_HEADERS += \ qqmlwebchannelattached_p.h +} else { + DEFINES += QT_NO_JSVALUE } HEADERS += $$PUBLIC_HEADERS $$PRIVATE_HEADERS |