Support input panel data get 73/59773/2
authorHaifeng Deng <haifeng.deng@samsung.com>
Thu, 18 Feb 2016 10:22:56 +0000 (18:22 +0800)
committerJihoon Kim <jihoon48.kim@samsung.com>
Fri, 19 Feb 2016 04:41:58 +0000 (13:41 +0900)
Change-Id: Ib3d6f8e3354f128e516093a3fbfc1d41017630c1

src/e_mod_main.c [changed mode: 0755->0644]

old mode 100755 (executable)
new mode 100644 (file)
index d12c511..7119840
@@ -519,6 +519,24 @@ _e_text_input_method_context_cb_private_command(struct wl_client *client EINA_UN
                                         serial, command);
 }
 
+static void
+_e_text_input_method_context_cb_input_panel_data_update(struct wl_client *client EINA_UNUSED, struct wl_resource *resource, uint32_t serial, const char *data, uint32_t length)
+{
+   E_Input_Method_Context *context = wl_resource_get_user_data(resource);
+
+   if (!context)
+     {
+        wl_resource_post_error(resource,
+                               WL_DISPLAY_ERROR_INVALID_OBJECT,
+                               "No Input Method Context For Resource");
+        return;
+     }
+
+   if ((context->model) && (context->model->resource))
+     wl_text_input_send_input_panel_data(context->model->resource,
+                                         serial, data, length);
+}
+
 static const struct wl_input_method_context_interface _e_text_input_method_context_implementation = {
      _e_text_input_method_context_cb_destroy,
      _e_text_input_method_context_cb_string_commit,
@@ -535,7 +553,8 @@ static const struct wl_input_method_context_interface _e_text_input_method_conte
      _e_text_input_method_context_cb_language,
      _e_text_input_method_context_cb_text_direction,
      _e_text_input_method_context_cb_selection_region,
-     _e_text_input_method_context_cb_private_command
+     _e_text_input_method_context_cb_private_command,
+     _e_text_input_method_context_cb_input_panel_data_update
 };
 
 static void