diff options
author | wang_zhiqiang <wang_zhiqiang@dl.cn.nexty-ele.com> | 2018-11-14 11:14:04 +0800 |
---|---|---|
committer | wang_zhiqiang <wang_zhiqiang@dl.cn.nexty-ele.com> | 2018-11-21 16:51:10 +0800 |
commit | c0146077906057bf97688a617870228eaad0cf54 (patch) | |
tree | 7d7bcc9a8a58c8c1f137be3872b643566c08e78c /sample/simple-egl | |
parent | 43452ff8a759da135525678528c159f1e4e68504 (diff) |
add new features in homescreen-service and homescreenguppy_6.99.4guppy_6.99.3guppy_6.99.2guppy_6.99.1guppy/6.99.4guppy/6.99.3guppy/6.99.2guppy/6.99.16.99.46.99.36.99.26.99.1
homescreen-service: add five verbs.
1.showWindow: instead of tap_shortcut and show onscreen.
2.hideWindow: used when want to hide onscreen.
3.replyShowWindow: used when post onscreen reply information to application.
4.showNotification: used by application who want to display notification on homescreen top area.
5.showInformation: used by application who want to display information on homescreen botton area.
homescreen:
1.add fullscreen transfer button.
2.display notification and information.
Bug-AGL: SPEC-1931
Change-Id: Ie0753fe0656282b1ff8c04dcef625f2a4154edde
Signed-off-by: wang_zhiqiang <wang_zhiqiang@dl.cn.nexty-ele.com>
Diffstat (limited to 'sample/simple-egl')
-rw-r--r-- | sample/simple-egl/src/simple-egl.cpp | 14 |
1 files changed, 11 insertions, 3 deletions
diff --git a/sample/simple-egl/src/simple-egl.cpp b/sample/simple-egl/src/simple-egl.cpp index 4271a66..aa6ea19 100644 --- a/sample/simple-egl/src/simple-egl.cpp +++ b/sample/simple-egl/src/simple-egl.cpp @@ -569,9 +569,17 @@ init_hs(LibHomeScreen* hs){ return -1; } - hs->set_event_handler(LibHomeScreen::Event_TapShortcut, [](json_object *object){ - HMI_DEBUG("simple-egl","try to activesurface %s ", app_name.c_str()); - wm->activateWindow(main_role); + hs->set_event_handler(LibHomeScreen::Event_ShowWindow, [hs](json_object *object){ + HMI_DEBUG("simple-egl","try to activeWindow %s ", app_name.c_str()); + + struct json_object *param_obj = json_object_object_get(object, hs->_keyParameter); + const char *area = json_object_get_string( + json_object_object_get(param_obj, hs->_keyArea)); + // Application should call LibWindowmanager::activateWindow() in showWindow handler + if(area == nullptr) + wm->activateWindow(main_role, hs->_areaNormal); + else + wm->activateWindow(main_role, area); }); return 0; |