summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2020-04-27 09:24:33 +0200
committerQt Forward Merge Bot <qt_forward_merge_bot@qt-project.org>2020-04-29 13:37:11 +0200
commit62c1f2bf339bd9ee1d5bcee02d4b25fb11023a09 (patch)
tree9c7d4170f5158d0c6c8a5967b3948f5f04d7927b
parent6de540639f3148769f851340c6d9513c28fa0eb5 (diff)
parent55162f53d4b71ebf6b0891006a18a0815908380a (diff)
Merge "Merge remote-tracking branch 'origin/5.14' into 5.15.0"
-rw-r--r--dist/changes-5.14.249
-rw-r--r--src/android/bluetooth/src/org/qtproject/qt5/android/bluetooth/QtBluetoothLE.java33
-rw-r--r--src/bluetooth/qlowenergycontroller_winrt.cpp1
-rw-r--r--src/nfc/doc/src/nfc-overview.qdoc15
4 files changed, 79 insertions, 19 deletions
diff --git a/dist/changes-5.14.2 b/dist/changes-5.14.2
new file mode 100644
index 00000000..4b0fa8a8
--- /dev/null
+++ b/dist/changes-5.14.2
@@ -0,0 +1,49 @@
+Qt 5.14.2 is a bug-fix release. It maintains both forward and backward
+compatibility (source and binary) with Qt 5.14.0 through 5.14.1.
+
+For more details, refer to the online documentation included in this
+distribution. The documentation is also available online:
+
+https://doc.qt.io/qt-5/index.html
+
+The Qt version 5.14 series is binary compatible with the 5.13.x series.
+Applications compiled for 5.13 will continue to run with 5.14.
+
+Some of the changes listed in this file include issue tracking numbers
+corresponding to tasks in the Qt Bug Tracker:
+
+https://bugreports.qt.io/
+
+Each of these identifiers can be entered in the bug tracker to obtain more
+information about a particular change.
+
+****************************************************************************
+* QtBluetooth *
+****************************************************************************
+
+ - Windows:
+ * [QTBUG-80770] Fixed service state (DiscoveryRequired) when service
+ detail discovery fails.
+ * [QTBUG-81827] Avoid possible lock when calling
+ QBluetoothServer::hasPendingConnections.
+ - Android:
+ * Fixed the missing QLowEnergyService::error() signal emission if the
+ error was detected on the Java side. This probably cut 50% of all
+ errors out.
+ * Fixed runtime exception that happened when calling "stopLeScan" when
+ device's Bluetooth adapter is turned off.
+ * [QTBUG-81875] Fixed QBluetoothDeviceDiscoveryAgent with Android API 29.
+ * Fixed race condition where incoming and outgoing Low Energy requests
+ could overwrite each others payload.
+ - Linux:
+ * [QTBUG-81696] Added support for characteristic Write Without Response
+ requests when using BlueZ 5.50 or later.
+
+****************************************************************************
+* QtNFC *
+****************************************************************************
+
+ - Android:
+ * Fixed case when QNearFieldTarget::waitForRequestCompleted() did not stop
+ early (caused overly long timeout case) despite QNearFieldTarget::sendCommand()
+ having failed already.
diff --git a/src/android/bluetooth/src/org/qtproject/qt5/android/bluetooth/QtBluetoothLE.java b/src/android/bluetooth/src/org/qtproject/qt5/android/bluetooth/QtBluetoothLE.java
index 3e602186..e9717a1d 100644
--- a/src/android/bluetooth/src/org/qtproject/qt5/android/bluetooth/QtBluetoothLE.java
+++ b/src/android/bluetooth/src/org/qtproject/qt5/android/bluetooth/QtBluetoothLE.java
@@ -296,7 +296,7 @@ public class QtBluetoothLE {
//unlock the queue for next item
synchronized (readWriteQueue) {
- ioJobPending = false;
+ pendingJob = null;
}
performNextIO();
@@ -309,7 +309,7 @@ public class QtBluetoothLE {
if (requestTimedOut) {
Log.w(TAG, "Late char read reply after timeout was hit for handle " + foundHandle);
// Timeout has hit before this response -> ignore the response
- // no need to unlock ioJobPending -> the timeout has done that already
+ // no need to unlock pendingJob -> the timeout has done that already
return;
}
@@ -349,7 +349,7 @@ public class QtBluetoothLE {
//unlock the queue for next item
synchronized (readWriteQueue) {
- ioJobPending = false;
+ pendingJob = null;
}
performNextIO();
@@ -373,7 +373,7 @@ public class QtBluetoothLE {
if (requestTimedOut) {
Log.w(TAG, "Late char write reply after timeout was hit for handle " + handle);
// Timeout has hit before this response -> ignore the response
- // no need to unlock ioJobPending -> the timeout has done that already
+ // no need to unlock pendingJob -> the timeout has done that already
return;
}
@@ -386,9 +386,10 @@ public class QtBluetoothLE {
errorCode = 2; break; // CharacteristicWriteError
}
- byte[] value = pendingJob.newValue;
+ byte[] value;
synchronized (readWriteQueue) {
- ioJobPending = false;
+ value = pendingJob.newValue;
+ pendingJob = null;
}
leCharacteristicWritten(qtObject, handle+1, value, errorCode);
performNextIO();
@@ -419,7 +420,7 @@ public class QtBluetoothLE {
//unlock the queue for next item
synchronized (readWriteQueue) {
- ioJobPending = false;
+ pendingJob = null;
}
performNextIO();
return;
@@ -432,7 +433,7 @@ public class QtBluetoothLE {
Log.w(TAG, "Late descriptor read reply after timeout was hit for handle " +
foundHandle);
// Timeout has hit before this response -> ignore the response
- // no need to unlock ioJobPending -> the timeout has done that already
+ // no need to unlock pendingJob -> the timeout has done that already
return;
}
@@ -491,7 +492,7 @@ public class QtBluetoothLE {
//unlock the queue for next item
synchronized (readWriteQueue) {
- ioJobPending = false;
+ pendingJob = null;
}
performNextIO();
@@ -512,7 +513,7 @@ public class QtBluetoothLE {
Log.w(TAG, "Late descriptor write reply after timeout was hit for handle " +
handle);
// Timeout has hit before this response -> ignore the response
- // no need to unlock ioJobPending -> the timeout has done that already
+ // no need to unlock pendingJob -> the timeout has done that already
return;
}
@@ -526,7 +527,7 @@ public class QtBluetoothLE {
}
synchronized (readWriteQueue) {
- ioJobPending = false;
+ pendingJob = null;
}
leDescriptorWritten(qtObject, handle+1, descriptor.getValue(), errorCode);
@@ -559,12 +560,12 @@ public class QtBluetoothLE {
if (requestTimedOut) {
Log.w(TAG, "Late mtu reply after timeout was hit");
// Timeout has hit before this response -> ignore the response
- // no need to unlock ioJobPending -> the timeout has done that already
+ // no need to unlock pendingJob -> the timeout has done that already
return;
}
synchronized (readWriteQueue) {
- ioJobPending = false;
+ pendingJob = null;
}
performNextIO();
@@ -724,7 +725,6 @@ public class QtBluetoothLE {
private final LinkedList<ReadWriteJob> readWriteQueue = new LinkedList<ReadWriteJob>();
- private boolean ioJobPending;
private ReadWriteJob pendingJob;
/*
@@ -1247,7 +1247,7 @@ public class QtBluetoothLE {
{
//unlock the queue for next item
synchronized (readWriteQueue) {
- ioJobPending = false;
+ pendingJob = null;
}
performNextIOThreaded();
@@ -1308,7 +1308,7 @@ public class QtBluetoothLE {
int handle = HANDLE_FOR_RESET;
synchronized (readWriteQueue) {
- if (readWriteQueue.isEmpty() || ioJobPending)
+ if (readWriteQueue.isEmpty() || pendingJob != null)
return;
nextJob = readWriteQueue.remove();
@@ -1352,7 +1352,6 @@ public class QtBluetoothLE {
if (skip) {
handleForTimeout.set(HANDLE_FOR_RESET); // not a pending call -> release atomic
} else {
- ioJobPending = true;
pendingJob = nextJob;
timeoutHandler.postDelayed(new TimeoutRunnable(
modifiedReadWriteHandle(handle, nextJob.jobType)), RUNNABLE_TIMEOUT);
diff --git a/src/bluetooth/qlowenergycontroller_winrt.cpp b/src/bluetooth/qlowenergycontroller_winrt.cpp
index ab566bd9..abe3392a 100644
--- a/src/bluetooth/qlowenergycontroller_winrt.cpp
+++ b/src/bluetooth/qlowenergycontroller_winrt.cpp
@@ -282,6 +282,7 @@ void QLowEnergyControllerPrivateWinRT::connectToDevice()
qCDebug(QT_BT_WINRT) << "Could not find LE device";
setError(QLowEnergyController::InvalidBluetoothAdapterError);
setState(QLowEnergyController::UnconnectedState);
+ return;
}
BluetoothConnectionStatus status;
hr = mDevice->get_ConnectionStatus(&status);
diff --git a/src/nfc/doc/src/nfc-overview.qdoc b/src/nfc/doc/src/nfc-overview.qdoc
index 6ac5c1dc..cb10b400 100644
--- a/src/nfc/doc/src/nfc-overview.qdoc
+++ b/src/nfc/doc/src/nfc-overview.qdoc
@@ -45,8 +45,19 @@ With the Qt NFC API typical use cases are:
The following sections describe how to use Qt NFC C++ classes and QML types for the above use cases.
-\note On Android, Qt Nfc only works in foreground applications. Android services are not supported which is due to
-API limitations on the Android side.
+\note On Android, the detection of new NFC tags only works in foreground applications. Android
+services do not support this because of API limitations on the Android side. The only way to use a
+\l{https://developer.android.com/reference/android/nfc/Tag}{Tag} in a service is to provide an
+\l{https://developer.android.com/guide/components/aidl}{AIDL} interface accepting the Tag and forward
+it to Qt as shown in the following example.
+
+\code
+ public void setTag(Tag pTag) {
+ Intent newIntent = new Intent();
+ newIntent.putExtra(NfcAdapter.EXTRA_TAG, pTag);
+ QtNative.onNewIntent(newIntent);
+ }
+\ endcode
\section1 C++ Overview