From 7e38cf4ed75622fb05be585f2d2d99ebd5d172ec Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Fri, 15 Aug 2014 11:31:41 +0200 Subject: Do not warn if no config file is found. Since this is the default situation. Change-Id: I9ab76b8ef9402fe39df0aaa532b61bd43b520b71 Reviewed-by: Lorn Potter Reviewed-by: Alex Blasche --- src/sensors/qsensormanager.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/sensors') diff --git a/src/sensors/qsensormanager.cpp b/src/sensors/qsensormanager.cpp index abe5f853..3b86c669 100644 --- a/src/sensors/qsensormanager.cpp +++ b/src/sensors/qsensormanager.cpp @@ -105,7 +105,7 @@ public: #endif qCDebug(sensorsCategory) << "Loading config from" << config; if (!QFile::exists(config)) { - qCWarning(sensorsCategory) << "There is no config file" << config; + qCDebug(sensorsCategory) << "There is no config file" << config; return; } QFile cfgfile(config); -- cgit v1.2.3 From fd3e65ef5ab6eb8e4b5bdad380d1f6862799856c Mon Sep 17 00:00:00 2001 From: Eike Ziller Date: Fri, 15 Aug 2014 11:21:43 +0200 Subject: Do not warn when failing to load static plugins as sensor plugins Since the list of static plugins can contain all kinds of plugins, failing there is expected. Change-Id: Ia5051c75691717b2e7279a68ea06f7697cbca053 Reviewed-by: Alex Blasche --- src/sensors/qsensormanager.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/sensors') diff --git a/src/sensors/qsensormanager.cpp b/src/sensors/qsensormanager.cpp index 3b86c669..d1a570ee 100644 --- a/src/sensors/qsensormanager.cpp +++ b/src/sensors/qsensormanager.cpp @@ -176,7 +176,7 @@ public Q_SLOTS: Q_GLOBAL_STATIC(QSensorManagerPrivate, sensorManagerPrivate) -static void initPlugin(QObject *o) +static void initPlugin(QObject *o, bool warnOnFail = true) { qCDebug(sensorsCategory) << "Init plugin" << o; if (!o) { @@ -202,7 +202,7 @@ static void initPlugin(QObject *o) qCDebug(sensorsCategory) << "Register sensors for " << plugin; d->seenPlugins.insert(o); plugin->registerSensors(); - } else { + } else if (warnOnFail) { qCWarning(sensorsCategory) << "Can't cast to plugin" << o; } } @@ -216,7 +216,7 @@ void QSensorManagerPrivate::loadPlugins() SENSORLOG() << "initializing static plugins"; // Qt-style static plugins Q_FOREACH (QObject *plugin, QPluginLoader::staticInstances()) { - initPlugin(plugin); + initPlugin(plugin, false/*do not warn on fail*/); } if (d->loadExternalPlugins) { -- cgit v1.2.3 From f33363d292484f0fe62b177df0fd8080910d01f9 Mon Sep 17 00:00:00 2001 From: Samuel Gaist Date: Sun, 17 Aug 2014 15:27:22 +0200 Subject: Add missing private headers warning Change-Id: I06883e0f2bb16999f13993b69b3701443912c5cc Reviewed-by: Alex Blasche Reviewed-by: Lorn Potter --- src/sensors/gestures/qsensorgesturemanagerprivate_p.h | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'src/sensors') diff --git a/src/sensors/gestures/qsensorgesturemanagerprivate_p.h b/src/sensors/gestures/qsensorgesturemanagerprivate_p.h index 0994b2ab..e0d45527 100644 --- a/src/sensors/gestures/qsensorgesturemanagerprivate_p.h +++ b/src/sensors/gestures/qsensorgesturemanagerprivate_p.h @@ -42,6 +42,17 @@ #ifndef QSENSORGESTUREMANAGERPRIVATE_P_H #define QSENSORGESTUREMANAGERPRIVATE_P_H +// +// W A R N I N G +// ------------- +// +// This file is not part of the Qt API. It exists purely as an +// implementation detail. This header file may change from version to +// version without notice, or even be removed. +// +// We mean it. +// + #include #include #include -- cgit v1.2.3