summaryrefslogtreecommitdiffstats
path: root/sample
diff options
context:
space:
mode:
authorTadao Tanikawa <tanikawa.tadao@jp.panasonic.com>2018-08-24 04:42:40 +0000
committerTadao Tanikawa <tanikawa.tadao@jp.panasonic.com>2018-08-24 10:57:37 +0000
commitd22ffadbe9fcb13144264e71da300bdf56724906 (patch)
treef6bf54605c6d5c1504b74bf7a35d2c19dd72a0fb /sample
parent58d5aa69c638b5e6d59f858516385e01fe248031 (diff)
Revert "Use appid between homescreen-service and apps"flounder_5.99.4flounder/5.99.45.99.4
This reverts commit 58d5aa69c638b5e6d59f858516385e01fe248031. Bug-AGL: SPEC-1685 Change-Id: I166edba9dcc41a7f2e5d9c7a9a6bd75216a27be8 Signed-off-by: Tadao Tanikawa <tanikawa.tadao@jp.panasonic.com>
Diffstat (limited to 'sample')
-rw-r--r--sample/simple-egl/src/simple-egl.cpp16
1 files changed, 11 insertions, 5 deletions
diff --git a/sample/simple-egl/src/simple-egl.cpp b/sample/simple-egl/src/simple-egl.cpp
index f56cf4d..be694d7 100644
--- a/sample/simple-egl/src/simple-egl.cpp
+++ b/sample/simple-egl/src/simple-egl.cpp
@@ -579,11 +579,17 @@ init_hs(LibHomeScreen* hs){
}
hs->set_event_handler(LibHomeScreen::Event_TapShortcut, [](json_object *object){
- HMI_DEBUG("simple-egl","try to activesurface %s ", app_name.c_str());
- json_object *obj = json_object_new_object();
- json_object_object_add(obj, wm->kKeyDrawingName, json_object_new_string(app_name.c_str()));
- json_object_object_add(obj, wm->kKeyDrawingArea, json_object_new_string("normal.full"));
- wm->activateSurface(obj);
+ const char *application_name = json_object_get_string(
+ json_object_object_get(object, "application_name"));
+ HMI_DEBUG("simple-egl","Event_TapShortcut application_name = %s ", application_name);
+ if(strcmp(application_name, app_name.c_str()) == 0)
+ {
+ HMI_DEBUG("simple-egl","try to activesurface %s ", app_name.c_str());
+ json_object *obj = json_object_new_object();
+ json_object_object_add(obj, wm->kKeyDrawingName, json_object_new_string(app_name.c_str()));
+ json_object_object_add(obj, wm->kKeyDrawingArea, json_object_new_string("normal.full"));
+ wm->activateSurface(obj);
+ }
});
return 0;