summaryrefslogtreecommitdiffstats
path: root/src/bluetooth/android
diff options
context:
space:
mode:
authorAlex Blasche <alexander.blasche@theqtcompany.com>2015-01-19 11:04:06 +0100
committerAlex Blasche <alexander.blasche@theqtcompany.com>2015-02-02 08:02:42 +0000
commitdf1320d940d56a2a8d2b98bde1bce1c4124e9950 (patch)
treebcdf0cf18f28601f727a93ba6748553188d8b839 /src/bluetooth/android
parentcc5a732f3dda39b378459d38d46565f0ce8ef0c3 (diff)
Android: Enable pairing for Android v15+
The required API became public in Android v19 which is what was used as check so far. However the same API was already privately provided since Android v15. THis patch ensures that older Android versions can create pairing requests too. This patch was provided by George Najarian. Task-number: QTBUG-43757 Change-Id: I0f38e538a972341a6acf719098f1010e52b639b7 Reviewed-by: BogDan Vatra <bogdan@kde.org> Reviewed-by: Timur Pocheptsov <Timur.Pocheptsov@digia.com>
Diffstat (limited to 'src/bluetooth/android')
-rw-r--r--src/bluetooth/android/localdevicebroadcastreceiver.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/bluetooth/android/localdevicebroadcastreceiver.cpp b/src/bluetooth/android/localdevicebroadcastreceiver.cpp
index c54c5e32..a3b92252 100644
--- a/src/bluetooth/android/localdevicebroadcastreceiver.cpp
+++ b/src/bluetooth/android/localdevicebroadcastreceiver.cpp
@@ -50,8 +50,8 @@ LocalDeviceBroadcastReceiver::LocalDeviceBroadcastReceiver(QObject *parent) :
addAction(valueForStaticField(JavaNames::BluetoothAdapter, JavaNames::ActionScanModeChanged));
addAction(valueForStaticField(JavaNames::BluetoothDevice, JavaNames::ActionAclConnected));
addAction(valueForStaticField(JavaNames::BluetoothDevice, JavaNames::ActionAclDisconnected));
- if (QtAndroidPrivate::androidSdkVersion() >= 19)
- addAction(valueForStaticField(JavaNames::BluetoothDevice, JavaNames::ActionPairingRequest)); //API 19
+ if (QtAndroidPrivate::androidSdkVersion() >= 15)
+ addAction(valueForStaticField(JavaNames::BluetoothDevice, JavaNames::ActionPairingRequest)); //API 15
//cache integer values for host & bonding mode
//don't use the java fields directly but refer to them by name