diff options
author | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2023-05-22 10:09:51 +0200 |
---|---|---|
committer | Volker Hilsheimer <volker.hilsheimer@qt.io> | 2023-05-23 08:46:24 +0200 |
commit | 03e3391929a7d754c57f2ed0e8e5941946827932 (patch) | |
tree | 24d10afa53c79413accbb92985317199159fd417 /src/bluetooth/qbluetoothuuid.h | |
parent | 2254bb455f90351e59ebad7ee41a2b83b88fd223 (diff) |
Follow up on change to QUuid in qtbase
The unit test fails to build without allowing a QBluetoothUuid to
be created explicitly from an 128-bit integer. Since the constructor
taking a quint128 has been removed from Qt 6.6, and since the
constructor from QUuid is explicit, we need to add a constructor from
the QUuid::Id128Bytes union type.
To avoid that QtCore/qtypes.h declares the quint128 typedef we have
to include all the headers that qtypes.h includes into removed_api.cpp
before undefining the __SIZEOF_INT128__ symbol.
Change-Id: If857faefc253dbbe6cf91bd13bdc31f31cdfb54e
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'src/bluetooth/qbluetoothuuid.h')
-rw-r--r-- | src/bluetooth/qbluetoothuuid.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/bluetooth/qbluetoothuuid.h b/src/bluetooth/qbluetoothuuid.h index 0978780d..43fbff5c 100644 --- a/src/bluetooth/qbluetoothuuid.h +++ b/src/bluetooth/qbluetoothuuid.h @@ -351,6 +351,8 @@ public: explicit constexpr QBluetoothUuid(quint32 uuid) noexcept : QUuid(uuid, 0x0, 0x1000, 0x80, 0x00, 0x00, 0x80, 0x5f, 0x9b, 0x34, 0xfb) {}; + explicit QBluetoothUuid(QUuid::Id128Bytes uuid) noexcept + : QUuid(uuid) {}; explicit QBluetoothUuid(const QString &uuid); QBluetoothUuid(const QBluetoothUuid &uuid) = default; QBluetoothUuid(const QUuid &uuid); |