diff options
author | Hwankyu Jhun <h.jhun@samsung.com> | 2019-04-10 19:33:30 +0900 |
---|---|---|
committer | Hwankyu Jhun <h.jhun@samsung.com> | 2019-04-11 10:27:51 +0900 |
commit | b82ce0fef19b830984c144335e2686c5c77095b9 (patch) | |
tree | 8b5440563eb55f47cff4f49cf1180e941adf685c | |
parent | 9e1fc2333397a14f21bb599e810a3110bea3a02e (diff) | |
download | app-core-b82ce0fef19b830984c144335e2686c5c77095b9.tar.gz app-core-b82ce0fef19b830984c144335e2686c5c77095b9.tar.bz2 app-core-b82ce0fef19b830984c144335e2686c5c77095b9.zip |
Fix voice-control-elm initialization
If the automode of voice touch feature is not enabled,
appcore-efl-base doesn't load libvc-control-elm library.
Change-Id: I6e297c98aa661e3b9138f00a481191c098f61d4d
Signed-off-by: Hwankyu Jhun <h.jhun@samsung.com>
-rw-r--r-- | src/efl_base/appcore_efl_base.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/src/efl_base/appcore_efl_base.c b/src/efl_base/appcore_efl_base.c index 5280f96..a4e2a04 100644 --- a/src/efl_base/appcore_efl_base.c +++ b/src/efl_base/appcore_efl_base.c @@ -120,6 +120,9 @@ static void __vc_elm_init(void) { int vt_automode = 0; + if (!__vc_elm_handle) + return; + vconf_notify_key_changed(VCONFKEY_VC_VOICE_TOUCH_AUTOMODE, __vc_vtauto_changed_cb, NULL); vconf_get_bool(VCONFKEY_VC_VOICE_TOUCH_AUTOMODE, &vt_automode); @@ -134,6 +137,9 @@ static void __vc_elm_init(void) static void __vc_elm_finish(void) { + if (!__vc_elm_handle) + return; + vconf_ignore_key_changed(VCONFKEY_VC_VOICE_TOUCH_AUTOMODE, __vc_vtauto_changed_cb); if (__vc_elm_initialized) { @@ -173,6 +179,7 @@ static void __efl_app_init(int argc, char **argv, void *data) { int hint; const char *hwacc; + int vt_automode = 0; elm_init(argc, argv); @@ -192,7 +199,11 @@ static void __efl_app_init(int argc, char **argv, void *data) } } - __vc_elm_thread = g_thread_new("vc-elm-loader", __vc_elm_loader, NULL); + vconf_get_int(VCONFKEY_VC_VOICE_TOUCH_AUTOMODE, &vt_automode); + if (vt_automode) { + __vc_elm_thread = g_thread_new("vc-elm-loader", + __vc_elm_loader, NULL); + } } static void __efl_app_finish(void) |