summaryrefslogtreecommitdiffstats
path: root/src/bluetooth/qbluetoothlocaldevice_qnx.cpp
diff options
context:
space:
mode:
authorFabian Bumberger <fbumberger@rim.com>2013-08-06 17:12:02 +0200
committerThe Qt Project <gerrit-noreply@qt-project.org>2013-08-06 17:39:47 +0200
commit7ef083c14da6dcab28ada7e7fabe38d639908011 (patch)
tree32b4a28a13958c4e0dc4630d4b5542c9ca769360 /src/bluetooth/qbluetoothlocaldevice_qnx.cpp
parent19f334fb56bcaf15c5f2d9bbe9c79cd8d3be4dfa (diff)
QNX: Emiting HostPoweredOff when BT is shut down
Change-Id: I14d01fb7ec6795a31ac9f239d34f3f02fd0880b5 Reviewed-by: Alex Blasche <alexander.blasche@digia.com>
Diffstat (limited to 'src/bluetooth/qbluetoothlocaldevice_qnx.cpp')
-rw-r--r--src/bluetooth/qbluetoothlocaldevice_qnx.cpp5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/bluetooth/qbluetoothlocaldevice_qnx.cpp b/src/bluetooth/qbluetoothlocaldevice_qnx.cpp
index a75347c4..e93c490c 100644
--- a/src/bluetooth/qbluetoothlocaldevice_qnx.cpp
+++ b/src/bluetooth/qbluetoothlocaldevice_qnx.cpp
@@ -142,6 +142,7 @@ QBluetoothLocalDevicePrivate::QBluetoothLocalDevicePrivate(QBluetoothLocalDevice
ppsRegisterForEvent(QStringLiteral("access_changed"), this);
ppsRegisterForEvent(QStringLiteral("pairing_complete"), this);
ppsRegisterForEvent(QStringLiteral("device_deleted"), this);
+ ppsRegisterForEvent(QStringLiteral("radio_shutdown"), this);
}
QBluetoothLocalDevicePrivate::~QBluetoothLocalDevicePrivate()
@@ -150,6 +151,7 @@ QBluetoothLocalDevicePrivate::~QBluetoothLocalDevicePrivate()
ppsUnregisterForEvent(QStringLiteral("access_changed"), this);
ppsUnregisterForEvent(QStringLiteral("pairing_complete"), this);
ppsUnregisterForEvent(QStringLiteral("device_deleted"), this);
+ ppsUnregisterForEvent(QStringLiteral("radio_shutdown"), this);
}
bool QBluetoothLocalDevicePrivate::isValid() const
@@ -296,6 +298,9 @@ void QBluetoothLocalDevicePrivate::controlEvent(ppsResult result)
result.dat.at(result.dat.indexOf(QStringLiteral("addr")) + 1));
Q_EMIT q_ptr->pairingFinished(address, QBluetoothLocalDevice::Unpaired);
}
+ } else if (result.msg == QStringLiteral("radio_shutdown")) {
+ qBBBluetoothDebug() << "radio shutdown";
+ Q_EMIT q_ptr->hostModeStateChanged(QBluetoothLocalDevice::HostPoweredOff);
}
}