diff options
author | zheng_wenlong <wenlong_zheng@nexty-ele.com> | 2017-10-23 20:20:23 +0900 |
---|---|---|
committer | zheng_wenlong <wenlong_zheng@nexty-ele.com> | 2017-10-23 20:20:23 +0900 |
commit | a330391a355a9fb00a502fea0cf49d8c38443817 (patch) | |
tree | 39f415b483bbdac59faf9324ffb8daa3ba48dc2e /homescreen/src/applicationmodel.cpp | |
parent | 3d836c185f92fb38fed31e373f371187322b2f3f (diff) |
Add debug message control by envirment
Add HMI_DEBUG to print debug message,
It control by USE_HMI_DEBUG envirment.
Signed-off-by: zheng_wenlong <wenlong_zheng@nexty-ele.com>
Diffstat (limited to 'homescreen/src/applicationmodel.cpp')
-rw-r--r-- | homescreen/src/applicationmodel.cpp | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/homescreen/src/applicationmodel.cpp b/homescreen/src/applicationmodel.cpp index 08b1a55..f01df06 100644 --- a/homescreen/src/applicationmodel.cpp +++ b/homescreen/src/applicationmodel.cpp @@ -19,7 +19,7 @@ #include "applicationmodel.h" #include "appinfo.h" -#include <QtCore/QDebug> +#include "hmi-debug.h" #include <QtDBus/QDBusInterface> #include <QtDBus/QDBusReply> @@ -63,11 +63,11 @@ ApplicationModel::Private::Private() auto const icon = get_icon_name(jso); // Hide HomeScreen icon itself - if (name != "homescreen-2017") { + if (name != "homescreen-2017" && name != "OnScreenApp") { this->data.append(AppInfo(icon, name, id)); } - qDebug() << "name:" << name << "icon:" << icon << "id:" << id; + HMI_DEBUG("HomeScreen","name: %s icon: %s id: %s.", name.toStdString().c_str(), icon.toStdString().c_str(), id.toStdString().c_str()); } } @@ -138,19 +138,19 @@ void ApplicationModel::move(int from, int to) if (to < 0 || to > rowCount()) return; if (from < to) { if (!beginMoveRows(parent, from, from, parent, to + 1)) { - qDebug() << from << to << false; + HMI_NOTICE("HomeScreen","from : %d, to : %d. false.", from, to); return; } d->data.move(from, to); endMoveRows(); } else if (from > to) { if (!beginMoveRows(parent, from, from, parent, to)) { - qDebug() << from << to << false; + HMI_NOTICE("HomeScreen","from : %d, to : %d. false.", from, to); return; } d->data.move(from, to); endMoveRows(); } else { - qDebug() << from << to << false; + HMI_NOTICE("HomeScreen","from : %d, to : %d. false.", from, to); } } |