summaryrefslogtreecommitdiffstats
path: root/src/bluetooth
Commit message (Collapse)AuthorAgeFilesLines
* Rename qlowenergycontroller_p... to qlowenergycontroller_dummyOliver Wolff2019-10-114-6/+6
| | | | | | | | | These files are no private headers/implementations but dummy versions of qlowenergycontroller. Change-Id: I2553ff933f45585edd690d807bf3c85a1906d1ad Reviewed-by: Alexandru Croitor <alexandru.croitor@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
* Fix \since version for createCentral()v5.14.0-alpha1Alex Blasche2019-09-161-1/+1
| | | | | Change-Id: I8d26fc7c4b7a93c4f839683feedd76cfbc1b5979 Reviewed-by: Albert Astals Cid <albert.astals.cid@kdab.com>
* Merge remote-tracking branch 'origin/5.13' into 5.14Timur Pocheptsov2019-09-1210-26/+31
|\ | | | | | | | | | | | | | | | | | | Conflicts: src/bluetooth/qbluetoothdevicediscoveryagent_darwin.mm src/bluetooth/qbluetoothserver_osx.mm src/bluetooth/qbluetoothserviceinfo_osx.mm src/bluetooth/qbluetoothsocket_osx.mm Change-Id: I24485ae835560fa1e57007fb684f6532db3e7922
| * Fix build errors with clang-cl on WindowsMårten Nordheim2019-09-053-0/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | The following errors are fixed: error: member access into incomplete type 'ABI::Windows::Devices::Bluetooth::IBluetoothDeviceStatics' error: unknown type name 'QMutex'; did you mean 'Mutex'? Task-number: QTQAINFRA-2139 Change-Id: I5e5d9c0776cd9feb5d682c5a0e1be2f5173101f9 Reviewed-by: Tony Sarajärvi <tony.sarajarvi@qt.io>
| * Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-08-101-1/+1
| |\ | | | | | | | | | Change-Id: I4cf492d5c7afde6b871ec4dc9198e9a794320e32
| | * Fix QLEAdvertisingData::setManufacturerData on AndroidAlex Blasche2019-08-071-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | The manufacturer data was not properly set because the related Java function requires a byte[] as second parameter. The equivelent JNI type is [B and not [B]. This caused a crash of the application. Change-Id: Iaa062ed9eb01e03d155583519d3f6a6bc01d72f7 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-07-271-1/+6
| |\| | | | | | | | | | Change-Id: I8c338f097a53c1235c0ea732f57421447125bde3
| | * winrt: Add limitations to bluetooth overview pageOliver Wolff2019-07-241-1/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Same as on Android, Obex is not supported on winrt. Even though QBluetoothServiceInfo has a small passage about winrt's limitations when it comes to RFCOMM. Users might miss these limitations as they are quite hidden. Make them more visible by also having them in the overview. Task-number: QTBUG-62520 Change-Id: Ibdf1a9b334b7138301e833981e67c7813488bbd1 Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | Merge remote-tracking branch 'origin/5.12' into 5.13Qt Forward Merge Bot2019-07-2011-44/+40
| |\| | | | | | | | | | Change-Id: I9493330b991b387163f46b8359a611aa7ff7745e
| | * Core/IO/Bluetooth - fix ambiguous conversions for macOSAndré Klitzing2019-07-196-26/+26
| | | | | | | | | | | | | | | | | | | | | This is a sibling of QTBUG-76847 on macOS instead of iOS. Change-Id: I3df6e28d65b9835f5f54e92d462d23423c48d835 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io>
| | * Do not handle PAIRING_VARIANT_PINAlex Blasche2019-07-173-13/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The user has to enter a pin in such cases. Since QBluetoothLocalDevice does not have an API to return a pin it makes no sense for QtBluetooth to handle this type of request. Android will provide its own fall back form. This patch is mostly a revert of f8c0572ddcd. Fixes: QTBUG-76565 Task-number: QTBUG-70295 Change-Id: I61062ac84ce508f3b82c7359a60d5c9c5bba86a4 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| | * winrt: Do not try to delete nullptr workerOliver Wolff2019-07-171-3/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | When calling QBluetoothDeviceDiscoveryAgentPrivate::stop the worker pointer is cleared in disconnectAndClearWorker so there is no need to call deleteLater (which will just result in a warning). Change-Id: I2713474833b61a12018ecfa6f9eb11618ed025a7 Task-number: QTBUG-75089 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| | * Fix compilation with C++20Marc Mutz2019-07-161-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | Implicit capture of 'this' in [=] is deprecated in C++20. Fix by using explicit capture. Change-Id: I96132d83d87ae61986ba1b1ea3f9cf8e50059f1f Reviewed-by: Mårten Nordheim <marten.nordheim@qt.io>
* | | Do not make blocking dbus calls in dbus callbacksAlex Blasche2019-09-112-40/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Doing so blocks the main event handler which could lead to a sluggish UI experience. Fixes: QTBUG-77390 Change-Id: Id3624d602131c04e535584a7a4740ce2f751daaf Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> Reviewed-by: Thiemo van Engelen <tvanengelen@victronenergy.com>
* | | Align deviceUpdated() & deviceDiscovered() behaviorAlex Blasche2019-09-112-43/+83
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The documentation for QBluetoothDeviceInfo::deviceDiscovered() and deviceUpdated() is fairly specific. This change brings Bluez5 behavior in line with Android and Apple platforms. Change-Id: Ia819f8b8a9b5c2268edbee0a3005e0129d0553e6 Reviewed-by: Timur Pocheptsov <timur.pocheptsov@qt.io> Reviewed-by: Thiemo van Engelen <tvanengelen@victronenergy.com>
* | | qbluetoothdevicediscoveryagent_winrt.cpp: Fix buildFriedemann Kleint2019-09-091-0/+1
| | | | | | | | | | | | | | | | | | | | | Add missing include for QMutex/Locker. Change-Id: I9e341b2ecaaae6e1b3a0bcf58ff7d890a4479091 Reviewed-by: André de la Rocha <andre.rocha@qt.io>
* | | Merge branch 'wip/win' into devOliver Wolff2019-08-2038-31/+4318
|\ \ \ | | | | | | | | | | | | | | | | | | | | | | | | [ChangeLog][QtBluetooth] Added possibility to build win32 backend which also works on Windows 7. Change-Id: I03aabdec781d0e8cef2e500ee94ab423b5ba2b56
| * | | Update Bluetooth docs to mention Win32 backendwip/winAndre de la Rocha2019-08-173-7/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change updates the Bluetooth documentation to reflect the addition of the native Win32 backend. Task-number: QTBUG-40698 Change-Id: I8d2bc2146527a17f1f47fff541730b94f58286fb Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | Merge remote-tracking branch 'origin/dev' into wip/winOliver Wolff2019-08-0781-4229/+3488
| |\ \ \ | | | | | | | | | | | | | | | Change-Id: I83175151c0eef1a11d2f21648cc04c86e46777c1
| * | | | Enable the use of the Win32 Bluetooth backendAndre de la Rocha2019-08-0522-297/+497
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This change enables the optional use of the Win32-based Bluetooth backend on Windows. By default, the WinRT backend is used, if supported by the platform. The use of the Win32 backend must be selected by the -native-win32-bluetooth configuration option. Task-number: QTBUG-40698 Change-Id: I6904bf077467d826e3ff5ad026ebae5f955f2e37 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | | win32-bt: fix warnings related to comparisons and initializersLubomir I. Ivanov2019-02-133-14/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Silence a couple of type of warnings: 1) warning: missing initializer for member '_BLUETOOTH_DEVICE_INFO::Address' [-Wmissing-field-initializers] BLUETOOTH_DEVICE_INFO deviceInfo = {0}; Unlike C, C++ is not happy about this type of initializer Use '{}' instead to init all members to zero or 'NULL' properly. 2) warning: comparison between signed and unsigned integer expressions [-Wsign-compare] if (socket != INVALID_SOCKET) { 'socket' is defined as 'int', while 'INVALID_SOCKET' is derived from 'SOCKET' which is of type UINT. Cast 'socket' to 'SOCKET' before performing the comparison. Change-Id: I9fcbff1c60ae36b8a8fed63382a8ffc0157f4923 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | Merge remote-tracking branch 'gerrit/dev' into wip/winAlex Blasche2019-02-1138-257/+369
| |\ \ \ \ | | | | | | | | | | | | | | | | | | Change-Id: I3402f42380068e3e6e7b3df8b15a712f0d86a3cd
| * \ \ \ \ Merge remote-tracking branch 'gerrit/dev' into win32Alex Blasche2018-11-22115-788/+4293
| |\ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | Change-Id: Ie99a67b63f8259227f42f5b464c6bbc16e79313b
| * | | | | | qbluetoothservicediscoveryagent_win: use lowercase importLubomir I. Ivanov2018-09-291-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The import of "WinSock2.h" fails on MXE environments because cross building from Linux to Windows makes it so that the filesystem is case sensitive. Change-Id: I6d89530f430eb45bf07154cffb5938eb3761ee1e Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
| * | | | | | win32-ble: store service handles until a service is destroyedLubomir I. Ivanov (VMware)2018-08-012-37/+38
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Recently, a problem was discovered that adding event registration on a descriptor does not work because the associated service handle is closed right after. For events to work a service should remain open if an event is registered for it. Store service handles (hService) is QLowEnergyServicePrivate. A handle is opened by QLowEnergyControllerPrivateWin32::discoverServiceDetails() and remains open until the device is disconnected. This removes the need to open/close services each time a Write/Read operation is performed on GATT characteristics / descriptors. Move the creation of the worker thread to connectToDevice(). Quit the thread in disconnectFromDevice() and also close any open service handles. Change-Id: Ia634af2e4225f5c1be93b0ddd17639c2dbd70c21 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | | | | win32: implement QBluetoothSocketEric Lemanissier2018-07-262-28/+358
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ib2b33490694c8608edda3eb0cbe7b8d0dd233254 Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com> Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
| * | | | | | Port win32 port to new QBluetoothSocketBasePrivate patternAlex Blasche2018-07-255-25/+248
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: If3fc4e1078c63d7ca2af0e79353a62b9a9bb0c6f Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | Merge remote-tracking branch 'gerrit/dev' into wip/winAlex Blasche2018-07-2555-757/+2217
| |\ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Ia5d83a88d6231984d9745d1c64f03553499a5882
| * | | | | | | win32: inline unnecessary functions in qbluetooth*discoveryagentEric Lemanissier2018-06-254-80/+44
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | by migrating to templated QMetaObject::invokeMethod Change-Id: I79e2dec7aa81987894a26859648d31da60cf47ee Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | | | | | win32: fix QBluetoothServiceDiscoveryAgent cleanupEric Lemanissier2018-06-211-37/+18
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | remove calls to WSACleanup, because it terminates use of the Winsock 2 DLL, including sockets operations. WSALookupServiceEnd only is needed. add missing WSALookupServiceEnd if pendingStop or error remove useless parameters of findFirst/NextService Change-Id: I587987b77c1be8f05a840e4333c31fd79af06ed3 Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | | win32: make bluetooth tst_startStopDeviceDiscoveries passEric Lemanissier2018-06-211-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | QVERIFY(discoveryAgent.errorString().isEmpty()) was failing Change-Id: I7b45db5b1af1ee3da75569d8855487c771cb29ed Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | | win32: modernize qbluetooth*discoveryagentEric Lemanissier2018-06-214-34/+28
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | arguments pass by ref NULL and 0 replaced with nullptr ::ZeroMemory replaced by default initialization range based for loop Change-Id: I393806f19155ee31e4ebe7f33ce22e9d14eafe40 Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | | win32: remove usage of QFuture in qbluetoothservicediscoveryagentLubomir I. Ivanov (VMware)2018-06-183-56/+111
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce usage of QThread for service discovery instead of QFuture. Details: - Make _q_nextSdpScan() accept arguments. - Make QBluetoothServiceDiscoveryAgentPrivate inherit QObject for QT_WIN_BLUETOOTH. - Remove usage of the member variables 'systemError', 'hSearch'. Pass values around, instead. - Add the helper structs 'FindServiceArguments' and 'FindServiceResult'. Change-Id: I4e2178b2a7b333c30a235a02807dd64526db4685 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | | | | | win32: remove usage of QFuture in qbluetoothdevicediscoveryagentLubomir I. Ivanov (VMware)2018-05-293-26/+72
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Introduce a couple of QThread instances and workers for the Bluetooth Classic and BLE device discovery. Replaces the usage of QFuture for this file. Remove includes of QtConcurrent. This introduced some errors which are solved by including: - QLoggingCategory in qbluetoothdevicediscoveryagent_win.cpp - QDataStream and QCoreApplication in qlowenergycontroller_win.cpp Change-Id: Iba2cbc147c714ae87515294d50cb4e502edd00a7 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | | Fix namespaced buildOliver Wolff2018-04-051-10/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: If20574e7bc182e5ee3d5adf6cc6d63cf9ee9d0ef Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com> Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | | | | | qlecontroller_win: read descriptors in a separate threadLubomir I. Ivanov (VMware)2018-03-292-26/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for the ThreadWorkerJob type ReadDesc in QLowEnergyControllerPrivateWin32. This type of job is responsible for reading GATT descriptors in a separate thread using the previously implemented ThreadWorkerJob scheme: - ThreadWorker::runPendingJob() - QLowEnergyControllerPrivateWin32::jobFinished() The blocking function in this case is getGattDescriptorValue(). Change-Id: I19298323f8ebc630b4dc34ae2e71c7e3c603beae Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
| * | | | | | | qlecontroller_win: write descriptors in a separate threadLubomir I. Ivanov (VMware)2018-03-292-62/+93
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for the ThreadWorkerJob type WriteDesc in QLowEnergyControllerPrivateWin32. This type of job is responsible for writing GATT descriptors in a separate thread using the previously implemented ThreadWorkerJob scheme: - ThreadWorker::runPendingJob() - QLowEnergyControllerPrivateWin32::jobFinished() The blocking function in this case is setGattDescriptorValue(). Change-Id: Ib221862d50cdbe5af951d4ad82850bea4f9a6645 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
| * | | | | | | qlecontroller_win: read characteristics in a separate threadLubomir I. Ivanov (VMware)2018-03-292-23/+49
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Add support for the ThreadWorkerJob type ReadChar in QLowEnergyControllerPrivateWin32. This type of job is responsible for reading GATT characteristics in a separate thread using the previously implemented ThreadWorkerJob scheme: - ThreadWorker::runPendingJob() - QLowEnergyControllerPrivateWin32::jobFinished() The blocking function in this case is getGattCharacteristicValue(). Change-Id: Idc87267a44aab51febae4addaca4b61d7e582a8a Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
| * | | | | | | Add a thread for QLowEnergyControllerPrivateWin32Lubomir I. Ivanov (VMware)2018-02-282-29/+140
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Create a re-usable thread ('thread') and worker ('treadWorker') in QLowEnergyControllerPrivateWin32 that have the same lifespan as the controller object. Add "job" support (ThreadWorkerJob) for the thread so that jobs are scheduled and executed sequentially. Each job should have a data struct. For writing that is WriteCharData. Handle writing of characteristics in: QLowEnergyControllerPrivateWin32::writeCharacteristic() QLowEnergyControllerPrivateWin32::jobFinished() ThreadWorker::runPendingJob() The above jobFinished() and runPendingJob() use a `switch` to determine the ThreadWorkerJob type. Change-Id: I3331e0d4adc29565a88fd792f9a54833881ea694 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | | qlecontroller_win: use lastIndexOf() in getDeviceAddress()Lubomir I. Ivanov (VMware)2018-02-281-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | getDeviceAddress() does not work for all path cases, thus instead of using: firstbound = servicePath.indexOf(...) use: firstbound = servicePath.lastIndexOf(...) Example path that breaks the current code: "\\\\?\\bthledevice#{00001800-0000-1000-8000-00805f9b34fb}_dev_vid&01008f_pid&b00d_rev&0100_00802534ce0e#8&5481851&5&0001#{00001800-0000-1000-8000-00805f9b34fb}" The current code works with paths of this format: "\\\\?\\BTHLEDevice#{00001800-0000-1000-8000-00805f9b34fb}_7c669d8a6d7a#8&35290589&1&0001#{00001800-0000-1000-8000-00805f9b34fb}" Notice that there are more than one "_" in the path that breaks. Change-Id: I5f081b78d8f5bc5693ba05c8e73d4dcf0b42b6b2 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | | qlecontroller_win: fix GetLastError() bug in getServiceSystemPath()Lubomir I. Ivanov (VMware)2018-02-281-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Fix strange bug in getServiceSystemPath() where after the first call to SetupDiGetDeviceInterfaceDetail(), GetLastError() returns 0 instead of ERROR_INSUFFICIENT_BUFFER (122). A fix is to use a `const DWORD` for the error immediately after the SetupDiGetDeviceInterfaceDetail() call. Possibly a compiler issue. Target toolchain is: gcc version 5.3.0 (i686-posix-dwarf-rev0, Built by MinGW-W64 project) Change-Id: Id197201e9e161f7240c339231990196f58cb87eb Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>
| * | | | | | | Reduce quantity of "reinterpret_cast" callsDenis Shienkov2018-02-281-9/+14
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | ... that simplified a code a bit. Change-Id: Ice7d082f005bfc36e86909784fb6fe38c6f6811f Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com> Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
| * | | | | | | Use WIN32_FROM_HRESULT macro to decode BLE system errorsDenis Shienkov2018-02-282-47/+69
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The GetLastError() function always returns the NO_ERROR code when any of the BluetoothGATTXXX() function fails. The reason is that the BluetoothGATTXXX() function uses the COM API, but the GetLastError() function uses the WIN32 API. We need to convert the HRESULT error code to the WIN32 error code directly, using a macro such as WIN32_FROM_HRESULT. Note: At least, it is reproduced with BluetoothGATTSetCharacteristicValue() function on Windows 10. Change-Id: I548e90bb16647c885b06c32397c277255fd362f4 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io> Reviewed-by: Lubomir I. Ivanov <neolit123@gmail.com>
| * | | | | | | Update license information for Windows filesLubomir I. Ivanov (VMware)2018-02-209-113/+161
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Iec42df246c5faec4260bbeb0dbf806477530d30f Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | | | | | Merge remote-tracking branch 'gerrit/dev' into winAlex Blasche2018-02-2035-57/+1387
| |\ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I4e86dcfe5088b0bd5087de309c435250c76d4718
| * | | | | | | | Add warning to private header qwinlowenergybluetooth_p.hLubomir I. Ivanov2017-11-221-0/+11
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Without this warning the build would not succeed. Change-Id: Ie43c494d80db2dfffa1f45c8896d996928678df0 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com> Reviewed-by: Alex Blasche <alexander.blasche@qt.io>
| * | | | | | | | Merge remote-tracking branch 'gerrit/dev' into winAlex Blasche2017-11-1571-1095/+2433
| |\ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I3a3557c6b8d565322358825d4b07c61cf6b97c9f
| * \ \ \ \ \ \ \ \ Merge "Merge remote-tracking branch 'gerrit/dev' into win" into ↵Alex Blasche2017-10-24107-392/+1833
| |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | refs/staging/wip/win
| | * \ \ \ \ \ \ \ \ Merge remote-tracking branch 'gerrit/dev' into winAlex Blasche2017-10-17107-392/+1833
| | |\ \ \ \ \ \ \ \ \ | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: I28ee9f95cc0fb85a36b5bd7b2ad87e0179446995
| * | | | | | | | | | | Make QtBluetooth on Win32 compile (following merge from dev)Alex Blasche2017-10-241-0/+10
| |/ / / / / / / / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change-Id: Idfc9f44cd9ab6064448804ed3a5d9fb81e644281 Reviewed-by: Denis Shienkov <denis.shienkov@gmail.com>