diff options
Diffstat (limited to 'src/bluetooth/qbluetoothlocaldevice.cpp')
-rw-r--r-- | src/bluetooth/qbluetoothlocaldevice.cpp | 11 |
1 files changed, 4 insertions, 7 deletions
diff --git a/src/bluetooth/qbluetoothlocaldevice.cpp b/src/bluetooth/qbluetoothlocaldevice.cpp index 0eb97647..ddbce02b 100644 --- a/src/bluetooth/qbluetoothlocaldevice.cpp +++ b/src/bluetooth/qbluetoothlocaldevice.cpp @@ -97,20 +97,17 @@ QT_BEGIN_NAMESPACE */ -namespace { -class LocalDeviceRegisterMetaTypes +void registerQBluetoothLocalDeviceMetaType() { -public: - LocalDeviceRegisterMetaTypes() - { + static bool initDone = false; + if (!initDone) { qRegisterMetaType<QBluetoothLocalDevice::HostMode>(); qRegisterMetaType<QBluetoothLocalDevice::Pairing>(); qRegisterMetaType<QBluetoothLocalDevice::Error>(); + initDone = true; } -} _registerLocalDeviceMetaTypes; } - #ifndef QT_OSX_BLUETOOTH /*! |