summaryrefslogtreecommitdiffstats
path: root/src/bluetooth/qbluetoothservicediscoveryagent_p.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/bluetooth/qbluetoothservicediscoveryagent_p.h')
-rw-r--r--src/bluetooth/qbluetoothservicediscoveryagent_p.h17
1 files changed, 15 insertions, 2 deletions
diff --git a/src/bluetooth/qbluetoothservicediscoveryagent_p.h b/src/bluetooth/qbluetoothservicediscoveryagent_p.h
index bfd6d954..65082558 100644
--- a/src/bluetooth/qbluetoothservicediscoveryagent_p.h
+++ b/src/bluetooth/qbluetoothservicediscoveryagent_p.h
@@ -46,13 +46,16 @@
#include "qbluetoothdeviceinfo.h"
#include "qbluetoothserviceinfo.h"
#include "qbluetoothservicediscoveryagent.h"
+#include "qlowenergyserviceinfo.h"
#include <QStack>
+#include <QStringList>
#ifdef QT_BLUEZ_BLUETOOTH
class OrgBluezManagerInterface;
class OrgBluezAdapterInterface;
class OrgBluezDeviceInterface;
+class OrgBluezCharacteristicInterface;
QT_BEGIN_NAMESPACE
class QDBusPendingCallWatcher;
class QXmlStreamReader;
@@ -108,7 +111,6 @@ public:
void setDiscoveryMode(QBluetoothServiceDiscoveryAgent::DiscoveryMode m) { mode = m; }
QBluetoothServiceDiscoveryAgent::DiscoveryMode DiscoveryMode() { return mode; }
- // private slots
void _q_deviceDiscoveryFinished();
void _q_deviceDiscovered(const QBluetoothDeviceInfo &info);
void _q_serviceDiscoveryFinished();
@@ -116,6 +118,12 @@ public:
#ifdef QT_BLUEZ_BLUETOOTH
void _q_discoveredServices(QDBusPendingCallWatcher *watcher);
void _q_createdDevice(QDBusPendingCallWatcher *watcher);
+ //Slots below are used for discovering Bluetooth Low Energy devices. It will be used with Bluez 5.x version.
+ /*
+ void _g_discoveredGattService();
+ void _q_discoverGattCharacteristics(QDBusPendingCallWatcher *watcher);
+ void _q_discoveredGattCharacteristic(QDBusPendingCallWatcher *watcher);
+ */
#endif
#ifdef QT_ANDROID_BLUETOOTH
void _q_processFetchedUuids(const QBluetoothAddress &address, const QList<QBluetoothUuid> &uuids);
@@ -149,6 +157,7 @@ private:
QSocketNotifier *rdNotifier;
QTimer m_queryTimer;
bool m_btInitialized;
+ bool m_serviceScanDone;
#endif
public:
@@ -168,11 +177,15 @@ private:
QBluetoothServiceDiscoveryAgent::DiscoveryMode mode;
bool singleDevice;
-
#ifdef QT_BLUEZ_BLUETOOTH
OrgBluezManagerInterface *manager;
OrgBluezAdapterInterface *adapter;
OrgBluezDeviceInterface *device;
+ // variables below are used for discovering Bluetooth Low Energy devices
+ OrgBluezCharacteristicInterface *characteristic;
+ QStringList gattServices;
+ QStringList gattCharacteristics;
+ QLowEnergyCharacteristicInfo gattCharacteristic;
#endif
#ifdef QT_ANDROID_BLUETOOTH