diff options
-rw-r--r-- | examples/bluetooth/scanner/scanner.qml | 2 | ||||
-rw-r--r-- | src/bluetooth/doc/snippets/doc_src_qtbluetooth.qml | 2 | ||||
-rw-r--r-- | src/bluetooth/doc/src/bluetooth-qml.qdoc | 2 | ||||
-rw-r--r-- | src/imports/bluetooth/plugin.cpp | 20 | ||||
-rw-r--r-- | src/imports/bluetooth/qdeclarativebluetoothdiscoverymodel.cpp | 3 | ||||
-rw-r--r-- | src/imports/bluetooth/qdeclarativebluetoothservice.cpp | 3 | ||||
-rw-r--r-- | src/imports/bluetooth/qdeclarativebluetoothsocket.cpp | 3 |
7 files changed, 22 insertions, 13 deletions
diff --git a/examples/bluetooth/scanner/scanner.qml b/examples/bluetooth/scanner/scanner.qml index 7ae0e28e..48b2ee53 100644 --- a/examples/bluetooth/scanner/scanner.qml +++ b/examples/bluetooth/scanner/scanner.qml @@ -40,7 +40,7 @@ ****************************************************************************/ import QtQuick 2.0 -import QtBluetooth 5.0 +import QtBluetooth 5.2 Item { id: top diff --git a/src/bluetooth/doc/snippets/doc_src_qtbluetooth.qml b/src/bluetooth/doc/snippets/doc_src_qtbluetooth.qml index 2d4280c3..eac7c144 100644 --- a/src/bluetooth/doc/snippets/doc_src_qtbluetooth.qml +++ b/src/bluetooth/doc/snippets/doc_src_qtbluetooth.qml @@ -39,7 +39,7 @@ ****************************************************************************/ //! [import] -import QtBluetooth 5.0 +import QtBluetooth 5.2 //! [import] //! [service] diff --git a/src/bluetooth/doc/src/bluetooth-qml.qdoc b/src/bluetooth/doc/src/bluetooth-qml.qdoc index 912f2153..f9ff3d30 100644 --- a/src/bluetooth/doc/src/bluetooth-qml.qdoc +++ b/src/bluetooth/doc/src/bluetooth-qml.qdoc @@ -28,7 +28,7 @@ /*! -\qmlmodule QtBluetooth 5.0 +\qmlmodule QtBluetooth 5.2 \title Qt Bluetooth QML Types \ingroup qmlmodules \brief Provides QML types for basic Bluetooth operations on devices diff --git a/src/imports/bluetooth/plugin.cpp b/src/imports/bluetooth/plugin.cpp index 9d3b816f..2311d6b8 100644 --- a/src/imports/bluetooth/plugin.cpp +++ b/src/imports/bluetooth/plugin.cpp @@ -56,13 +56,25 @@ class QBluetoothQmlPlugin : public QQmlExtensionPlugin public: void registerTypes(const char *uri) { - Q_ASSERT(uri == QLatin1String("QtBluetooth")); + // @uri QtBluetooth + + Q_ASSERT(uri == QStringLiteral("QtBluetooth")); int major = 5; int minor = 0; - qmlRegisterType<QDeclarativeBluetoothDiscoveryModel>(uri, major, minor, "BluetoothDiscoveryModel"); - qmlRegisterType<QDeclarativeBluetoothService>(uri, major, minor, "BluetoothService"); - qmlRegisterType<QDeclarativeBluetoothSocket>(uri, major, minor, "BluetoothSocket"); + + // Register the 5.0 types + //5.0 is silent and not advertised + qmlRegisterType<QDeclarativeBluetoothDiscoveryModel >(uri, major, minor, "BluetoothDiscoveryModel"); + qmlRegisterType<QDeclarativeBluetoothService >(uri, major, minor, "BluetoothService"); + qmlRegisterType<QDeclarativeBluetoothSocket >(uri, major, minor, "BluetoothSocket"); + + // Register the 5.2 types + minor = 2; + qmlRegisterType<QDeclarativeBluetoothDiscoveryModel >(uri, major, minor, "BluetoothDiscoveryModel"); + qmlRegisterType<QDeclarativeBluetoothService >(uri, major, minor, "BluetoothService"); + qmlRegisterType<QDeclarativeBluetoothSocket >(uri, major, minor, "BluetoothSocket"); + } }; diff --git a/src/imports/bluetooth/qdeclarativebluetoothdiscoverymodel.cpp b/src/imports/bluetooth/qdeclarativebluetoothdiscoverymodel.cpp index c2623ba0..8fc93e48 100644 --- a/src/imports/bluetooth/qdeclarativebluetoothdiscoverymodel.cpp +++ b/src/imports/bluetooth/qdeclarativebluetoothdiscoverymodel.cpp @@ -53,11 +53,10 @@ \qmltype BluetoothDiscoveryModel \instantiates QDeclarativeBluetoothDiscoveryModel \inqmlmodule QtBluetooth + \since 5.2 \brief Enables you to search for the Bluetooth devices and services in range. - The BluetoothDiscoveryModel type was introduced in \b{QtBluetooth 5.0}. - BluetoothDiscoveryModel provides a model of connectable services. The contents of the model can be filtered by UUID allowing discovery to be limited to a single service such as a game. diff --git a/src/imports/bluetooth/qdeclarativebluetoothservice.cpp b/src/imports/bluetooth/qdeclarativebluetoothservice.cpp index c4234933..be8f90c0 100644 --- a/src/imports/bluetooth/qdeclarativebluetoothservice.cpp +++ b/src/imports/bluetooth/qdeclarativebluetoothservice.cpp @@ -54,13 +54,12 @@ \qmltype BluetoothService \instantiates QDeclarativeBluetoothService \inqmlmodule QtBluetooth + \since 5.2 \brief Provides information about a particular Bluetooth service. \sa QBluetoothAddress \sa QBluetoothSocket - The BluetoothService type was introduced in \b{QtBluetooth 5.0}. - It allows a QML project to get information about a remote service, or describe a service for a BluetoothSocket to connect to. */ diff --git a/src/imports/bluetooth/qdeclarativebluetoothsocket.cpp b/src/imports/bluetooth/qdeclarativebluetoothsocket.cpp index 449e578a..ea9d9e6e 100644 --- a/src/imports/bluetooth/qdeclarativebluetoothsocket.cpp +++ b/src/imports/bluetooth/qdeclarativebluetoothsocket.cpp @@ -55,14 +55,13 @@ \qmltype BluetoothSocket \instantiates QDeclarativeBluetoothSocket \inqmlmodule QtBluetooth + \since 5.2 \brief Enables you to connect and communicate with a Bluetooth service or device. \sa QBluetoothSocket \sa QDataStream - The BluetoothSocket type was introduced in \b{QtBluetooth 5.0}. - It allows a QML class connect to another Bluetooth device and exchange strings with it. Data is sent and received using a QDataStream object allowing type safe transfers of QStrings. QDataStream is a well known format and can be |