aboutsummaryrefslogtreecommitdiffstats
path: root/HomeScreenAppFrameworkBinderAGL
diff options
context:
space:
mode:
authorTasuku Suzuki <tasuku.suzuki@qt.io>2016-11-21 14:40:40 +0900
committerJens Bocklage <jens_bocklage@mentor.com>2016-11-21 09:35:24 +0000
commit83cfbb9fe4bcc17f6b00c8a25aa3eb8c2c850ac0 (patch)
tree83c6f6484a0baf793eef722990d5911bbeeaad1c /HomeScreenAppFrameworkBinderAGL
parentc15499baf78f777de62899a376b0f3cd6b651920 (diff)
check ivi-layermanagement-api availability
replace #ifdef __arm__ with a definition that comes from availability test Change-Id: Id9fa4baefcc9f38acd3e98d40054040fc69029c6 Signed-off-by: Tasuku Suzuki <tasuku.suzuki@qt.io>
Diffstat (limited to 'HomeScreenAppFrameworkBinderAGL')
-rw-r--r--HomeScreenAppFrameworkBinderAGL/HomeScreenAppFrameworkBinderAGL.pro1
-rw-r--r--HomeScreenAppFrameworkBinderAGL/src/homescreenappframeworkbinderagl.cpp10
2 files changed, 5 insertions, 6 deletions
diff --git a/HomeScreenAppFrameworkBinderAGL/HomeScreenAppFrameworkBinderAGL.pro b/HomeScreenAppFrameworkBinderAGL/HomeScreenAppFrameworkBinderAGL.pro
index f194609..7cc7927 100644
--- a/HomeScreenAppFrameworkBinderAGL/HomeScreenAppFrameworkBinderAGL.pro
+++ b/HomeScreenAppFrameworkBinderAGL/HomeScreenAppFrameworkBinderAGL.pro
@@ -17,6 +17,7 @@ TARGET = HomeScreenAppFrameworkBinderAGL
QT = core dbus
include(../interfaces/interfaces.pri)
+include(../ivi_layermanagement_api.pri)
SOURCES += src/main.cpp \
src/homescreenappframeworkbinderagl.cpp
diff --git a/HomeScreenAppFrameworkBinderAGL/src/homescreenappframeworkbinderagl.cpp b/HomeScreenAppFrameworkBinderAGL/src/homescreenappframeworkbinderagl.cpp
index 91df6f7..593a882 100644
--- a/HomeScreenAppFrameworkBinderAGL/src/homescreenappframeworkbinderagl.cpp
+++ b/HomeScreenAppFrameworkBinderAGL/src/homescreenappframeworkbinderagl.cpp
@@ -39,7 +39,7 @@ HomeScreenAppFrameworkBinderAgl::HomeScreenAppFrameworkBinderAgl(QObject *parent
QDBusConnection::sessionBus(),
0);
-#ifdef __arm__
+#ifdef HAVE_IVI_LAYERMANAGEMENT_API
QString runnables = mp_dBusAfmUserProxy->runnables("{\"dummy\": \"entry\"}");
qDebug("runnables: %s", runnables.toStdString().c_str());
@@ -55,8 +55,7 @@ HomeScreenAppFrameworkBinderAgl::HomeScreenAppFrameworkBinderAgl(QObject *parent
m_apps.append(appInfo);
}
-#endif
-#ifdef __i386__
+#else
// for the simulation
/*AppInfo ai;
ai.setName("org.test.app1");
@@ -82,7 +81,7 @@ QList<AppInfo> HomeScreenAppFrameworkBinderAgl::getAvailableApps()
int HomeScreenAppFrameworkBinderAgl::launchApp(const QString &name)
{
int pid = -1;
-#ifdef __arm__
+#ifdef HAVE_IVI_LAYERMANAGEMENT_API
qDebug("launchApp name: %s", name.toStdString().c_str());
QString jsonLaunch = "{\"id\":\"" + name + "\", \"mode\":\"local\"}";
qDebug("jsonLaunch %s", jsonLaunch.toStdString().c_str());
@@ -110,8 +109,7 @@ int HomeScreenAppFrameworkBinderAgl::launchApp(const QString &name)
}
qDebug("launchApp pid: %d", pid);
-#endif
-#ifdef __i386__
+#else
qDebug("launchApp name: %s", name.toStdString().c_str());
pid = qrand();
#endif