summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLiang Qi <liang.qi@theqtcompany.com>2015-10-14 19:51:54 +0200
committerLiang Qi <liang.qi@theqtcompany.com>2015-10-14 19:51:54 +0200
commit5efb5dac71baf7910be0ebf5debb2b0236adf8fe (patch)
treee01842e7e0c86c57096a49012381bd37f69dad52
parent8bd96b78bdf3598549d9de4256af4df93781c528 (diff)
parentd8e357f75a05bce5e1286c94e2b1954f6591218e (diff)
Merge remote-tracking branch 'origin/5.6' into dev
-rw-r--r--dist/changes-5.5.132
-rw-r--r--[-rwxr-xr-x]examples/sensors/accelbubble/doc/images/accelbubble.pngbin5181 -> 5181 bytes
-rw-r--r--src/plugins/sensors/generic/main.cpp20
-rw-r--r--src/plugins/sensors/sensorfw/main.cpp3
-rw-r--r--src/sensors/doc/src/compatmap.qdoc2
-rw-r--r--src/sensors/doc/src/qtsensors-backend.qdoc14
-rw-r--r--src/sensors/doc/src/qtsensors5.qdoc8
-rw-r--r--tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp2
8 files changed, 59 insertions, 22 deletions
diff --git a/dist/changes-5.5.1 b/dist/changes-5.5.1
new file mode 100644
index 00000000..57567d5c
--- /dev/null
+++ b/dist/changes-5.5.1
@@ -0,0 +1,32 @@
+Qt 5.5.1 is a bug-fix release. It maintains both forward and backward
+compatibility (source and binary) with Qt 5.5.0.
+
+For more details, refer to the online documentation included in this
+distribution. The documentation is also available online:
+
+ http://doc.qt.io/qt-5.5/
+
+The Qt version 5.5 series is binary compatible with the 5.4.x series.
+Applications compiled for 5.4 will continue to run with 5.5.
+
+Some of the changes listed in this file include issue tracking numbers
+corresponding to tasks in the Qt Bug Tracker:
+
+ http://bugreports.qt.io/
+
+Each of these identifiers can be entered in the bug tracker to obtain more
+information about a particular change.
+
+****************************************************************************
+* Library *
+****************************************************************************
+
+****************************************************************************
+* Platform Specific Changes *
+****************************************************************************
+
+Sensor Framework platforms
+--------------------------
+
+ - [QTBUG-47854] Fixed interaction between generic and sensorfw plugin.
+
diff --git a/examples/sensors/accelbubble/doc/images/accelbubble.png b/examples/sensors/accelbubble/doc/images/accelbubble.png
index 84e876d5..84e876d5 100755..100644
--- a/examples/sensors/accelbubble/doc/images/accelbubble.png
+++ b/examples/sensors/accelbubble/doc/images/accelbubble.png
Binary files differ
diff --git a/src/plugins/sensors/generic/main.cpp b/src/plugins/sensors/generic/main.cpp
index 257e47e4..0fe3126d 100644
--- a/src/plugins/sensors/generic/main.cpp
+++ b/src/plugins/sensors/generic/main.cpp
@@ -72,10 +72,6 @@ public:
if (!QSensorManager::isBackendRegistered(QRotationSensor::type, genericrotationsensor::id))
QSensorManager::registerBackend(QRotationSensor::type, genericrotationsensor::id, this);
#endif
-#ifdef QTSENSORS_GENERICALSSENSOR
- if (!QSensorManager::isBackendRegistered(QAmbientLightSensor::type, genericalssensor::id))
- QSensorManager::registerBackend(QAmbientLightSensor::type, genericalssensor::id, this);
-#endif
#ifdef QTSENSORS_GENERICTILTSENSOR
if (!QSensorManager::isBackendRegistered(QTiltSensor::type, GenericTiltSensor::id))
QSensorManager::registerBackend(QTiltSensor::type, GenericTiltSensor::id, this);
@@ -89,15 +85,23 @@ public:
if (QSensorManager::isBackendRegistered(QRotationSensor::type, genericrotationsensor::id))
QSensorManager::unregisterBackend(QRotationSensor::type, genericrotationsensor::id);
#endif
-#ifdef QTSENSORS_GENERICALSSENSOR
- if (QSensorManager::isBackendRegistered(QAmbientLightSensor::type, genericalssensor::id))
- QSensorManager::unregisterBackend(QAmbientLightSensor::type, genericalssensor::id);
-#endif
#ifdef QTSENSORS_GENERICTILTSENSOR
if (QSensorManager::isBackendRegistered(QTiltSensor::type, GenericTiltSensor::id))
QSensorManager::unregisterBackend(QTiltSensor::type, GenericTiltSensor::id);
#endif
}
+
+ if (!QSensor::defaultSensorForType(QLightSensor::type).isEmpty()) {
+#ifdef QTSENSORS_GENERICALSSENSOR
+ if (!QSensorManager::isBackendRegistered(QAmbientLightSensor::type, genericalssensor::id))
+ QSensorManager::registerBackend(QAmbientLightSensor::type, genericalssensor::id, this);
+#endif
+ } else {
+#ifdef QTSENSORS_GENERICALSSENSOR
+ if (QSensorManager::isBackendRegistered(QAmbientLightSensor::type, genericalssensor::id))
+ QSensorManager::unregisterBackend(QAmbientLightSensor::type, genericalssensor::id);
+#endif
+ }
}
QSensorBackend *createBackend(QSensor *sensor)
diff --git a/src/plugins/sensors/sensorfw/main.cpp b/src/plugins/sensors/sensorfw/main.cpp
index b22b6474..9951f096 100644
--- a/src/plugins/sensors/sensorfw/main.cpp
+++ b/src/plugins/sensors/sensorfw/main.cpp
@@ -65,7 +65,8 @@ public:
QStringList keys = settings.allKeys();
for (int i=0,l=keys.size(); i<l; i++) {
QString type = keys.at(i);
- QSensorManager::registerBackend(type.toLocal8Bit(), settings.value(type).toByteArray(), this);
+ if (settings.value(type).toString().contains(QStringLiteral("sensorfw")))//register only ones we know
+ QSensorManager::registerBackend(type.toLocal8Bit(), settings.value(type).toByteArray(), this);
}
}
diff --git a/src/sensors/doc/src/compatmap.qdoc b/src/sensors/doc/src/compatmap.qdoc
index f6a99a9e..4f45fcbc 100644
--- a/src/sensors/doc/src/compatmap.qdoc
+++ b/src/sensors/doc/src/compatmap.qdoc
@@ -88,7 +88,7 @@
<td bgcolor="gray"></td>
<td bgcolor="green"></td>
<td bgcolor="gray"></td>
- <td bgcolor="gray"></td>
+ <td bgcolor="green"></td>
<td bgcolor="green"></td>
</tr>
<tr>
diff --git a/src/sensors/doc/src/qtsensors-backend.qdoc b/src/sensors/doc/src/qtsensors-backend.qdoc
index 98fcd741..65ea612b 100644
--- a/src/sensors/doc/src/qtsensors-backend.qdoc
+++ b/src/sensors/doc/src/qtsensors-backend.qdoc
@@ -26,7 +26,7 @@
****************************************************************************/
/*!
-\group sensors_backend_topics
+\page sensors-backend-topics.html
\title Qt Sensors Backend
\brief Describes how to use the Qt Sensors backend.
@@ -37,8 +37,6 @@ hardware sensors.
\section1 Overview
-\section1 Backend API
-
QSensor instances talk to a backend object. Backends are usually supplied
with the Qt Sensors library for a specific device, although third-party
backends may be used as well. A backend can talk directly to hardware, or
@@ -53,14 +51,16 @@ classes to use.
\section1 Backend Topics
-\generatelist related
-
+\list
+\li \l{Creating a sensor plugin}
+\li \l{Determining the default sensor for a type}
+\li \l{Dynamic Sensor Backend Registration}
+\endlist
*/
/*!
\page creating-a-sensor-plugin.html
\title Creating a sensor plugin
-\ingroup sensors_backend_topics
\section1 How a Sensor Plugin is Loaded
@@ -83,7 +83,6 @@ An example follows.
/*!
\page determining-the-default-sensor-for-a-type.html
\title Determining the default sensor for a type
-\ingroup sensors_backend_topics
\section1 Multiple Sensors Can Exist for a Type
@@ -141,7 +140,6 @@ it is specified in \c{Sensors.conf}.
/*!
\page dynamic-sensor-backend-registration.html
\title Dynamic Sensor Backend Registration
-\ingroup sensors_backend_topics
\section1 Static Backend Registration
diff --git a/src/sensors/doc/src/qtsensors5.qdoc b/src/sensors/doc/src/qtsensors5.qdoc
index 69e7abb0..bf7fa982 100644
--- a/src/sensors/doc/src/qtsensors5.qdoc
+++ b/src/sensors/doc/src/qtsensors5.qdoc
@@ -51,14 +51,14 @@
If the module is imported into a namespace, some additional methods become available.
- \code
+ \qml
import QtSensors 5.0
- ...
+ // ...
Component.onCompleted: {
var types = QmlSensors.sensorTypes();
console.log(types.join(", "));
}
- \endcode
+ \endqml
The documentation for the module API can be found in SensorGlobal.
@@ -75,4 +75,6 @@
The data from a sensor comes via a reading class.
\annotatedlist qml-sensors_reading
+
+ \section1 All QML Types
*/
diff --git a/tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp b/tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp
index 25863ec5..44fb3178 100644
--- a/tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp
+++ b/tests/auto/qsensorgestures/plugins/test/qtestrecognizer.cpp
@@ -53,7 +53,7 @@ void QTestRecognizer::timeout()
{
Q_EMIT detected("tested");
Q_EMIT tested();
- QTimer::singleShot(10,this, SLOT(timeout()));
+ QTimer::singleShot(100, this, SLOT(timeout()));
}