Fix IME string translation issue
[platform/core/uifw/libscl-core.git] / src / sclcoreui-efl.cpp
index be6a4db..60e0eb2 100644 (file)
@@ -138,7 +138,7 @@ void CSCLCoreUIEFL::set_keyboard_size_hints(SclSize portrait, SclSize landscape)
 #endif
 }
 
-static void language_changed_cb(keynode_t *key, void* data)
+static int language_changed_cb(void *event_info, void* data)
 {
     char clang[_POSIX_PATH_MAX] = {0};
     char *vconf_str = vconf_get_str(VCONFKEY_LANGSET);
@@ -155,6 +155,8 @@ static void language_changed_cb(keynode_t *key, void* data)
             callback->on_set_display_language(clang);
         }
     }
+
+    return 0;
 }
 
 static void accessibility_changed_cb(keynode_t *key, void* data)
@@ -452,7 +454,8 @@ int CSCLCoreUIEFL::create(void *data)
     ecore_x_icccm_name_class_set(elm_win_xwindow_get(main_window), "Virtual Keyboard", "ISF");
 #endif
 
-    vconf_notify_key_changed(VCONFKEY_LANGSET, language_changed_cb, NULL);
+    appcore_set_event_callback(APPCORE_EVENT_LANG_CHANGE, language_changed_cb, NULL);
+
     vconf_notify_key_changed(VCONFKEY_SETAPPL_ACCESSIBILITY_TTS, accessibility_changed_cb, NULL);
 
     /* Should we call these callback functions here? */
@@ -488,7 +491,8 @@ int CSCLCoreUIEFL::terminate(void *data)
     if (impl)
         impl->fini();
 
-    vconf_ignore_key_changed(VCONFKEY_LANGSET, language_changed_cb);
+    appcore_set_event_callback(APPCORE_EVENT_LANG_CHANGE, NULL, NULL);
+
     vconf_ignore_key_changed(VCONFKEY_SETAPPL_ACCESSIBILITY_TTS, accessibility_changed_cb);
 
 #ifndef WAYLAND