From 25e92bb91f2243a707db55b7d5e4db43f4411af8 Mon Sep 17 00:00:00 2001 From: Andreas Buhr <andreas.buhr@qt.io> Date: Fri, 12 Mar 2021 15:45:01 +0100 Subject: [PATCH] Use QtBluetooth enums from their namespace For increased type safety, some enums have been changed to scoped enums in Qt 6.2, see https://codereview.qt-project.org/c/qt/qtconnectivity/+/336678 This patch adapts qgroundcontrol to this change. Since C++11, enums inject their symbols in both their own and their parent namespace, so this patch can be merged right now. Signed-off-by: Andreas Buhr <andreas.buhr@qt.io> --- src/comm/BluetoothLink.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/comm/BluetoothLink.cc b/src/comm/BluetoothLink.cc index 0770a71..dc4a9bc 100644 --- a/src/comm/BluetoothLink.cc +++ b/src/comm/BluetoothLink.cc @@ -113,7 +113,7 @@ bool BluetoothLink::_hardwareConnect() _discoveryAgent->start(); #else _createSocket(); - _targetSocket->connectToService(QBluetoothAddress(qobject_cast<BluetoothConfiguration*>(_config.get())->device().address), QBluetoothUuid(QBluetoothUuid::SerialPort)); + _targetSocket->connectToService(QBluetoothAddress(qobject_cast<BluetoothConfiguration*>(_config.get())->device().address), QBluetoothUuid(QBluetoothUuid::ServiceClassUuid::SerialPort)); #endif return true; }