Remove code to use deprecated Ecore IMF APIs 52/209852/1
authorJihoon Kim <jihoon48.kim@samsung.com>
Fri, 12 Jul 2019 01:10:12 +0000 (10:10 +0900)
committerJihoon Kim <jihoon48.kim@samsung.com>
Fri, 12 Jul 2019 01:16:22 +0000 (10:16 +0900)
Change-Id: I4e575437e80bab6a5e887f006306e365f874057f
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
ism/extras/wayland_immodule/wayland_imcontext.c

index 822f768..a28505d 100644 (file)
@@ -503,7 +503,6 @@ autoperiod_insert (Ecore_IMF_Context *ctx)
             ev.n_chars = del_chars;
             ev.offset = del_chars * -1;
 
-            ecore_imf_context_delete_surrounding_event_add (ctx, ev.offset, ev.n_chars);
             ecore_imf_context_event_callback_call (ctx, ECORE_IMF_CALLBACK_DELETE_SURROUNDING, &ev);
 
             if (input_lang == INPUT_LANG_OTHER) {
@@ -516,7 +515,6 @@ autoperiod_insert (Ecore_IMF_Context *ctx)
                 fullstop_mark = eina_unicode_unicode_to_utf8 (wbuf, NULL);
             }
 
-            ecore_imf_context_commit_event_add (ctx, fullstop_mark);
             ecore_imf_context_event_callback_call (ctx, ECORE_IMF_CALLBACK_COMMIT, (void *)fullstop_mark);
 
             if (fullstop_mark) {
@@ -1310,7 +1308,6 @@ text_input_commit_string(void                 *data,
         return;
 
     if (old_preedit) {
-        ecore_imf_context_preedit_end_event_add(imcontext->ctx);
         ecore_imf_context_event_callback_call(imcontext->ctx,
                 ECORE_IMF_CALLBACK_PREEDIT_END,
                 NULL);
@@ -1331,7 +1328,6 @@ text_input_commit_string(void                 *data,
         free(ustr);
     }
 
-    ecore_imf_context_commit_event_add(imcontext->ctx, text);
     ecore_imf_context_event_callback_call(imcontext->ctx, ECORE_IMF_CALLBACK_COMMIT, (void *)text);
 }
 
@@ -1350,17 +1346,14 @@ commit_preedit(WaylandIMContext *imcontext)
     size_t commit_len = strlen(imcontext->preedit_commit);
 
     if (commit_len == 0) {
-        ecore_imf_context_preedit_start_event_add(imcontext->ctx);
         ecore_imf_context_event_callback_call(imcontext->ctx,
                 ECORE_IMF_CALLBACK_PREEDIT_START,
                 NULL);
 
-        ecore_imf_context_preedit_changed_event_add(imcontext->ctx);
         ecore_imf_context_event_callback_call(imcontext->ctx,
                 ECORE_IMF_CALLBACK_PREEDIT_CHANGED,
                 NULL);
 
-        ecore_imf_context_preedit_end_event_add(imcontext->ctx);
         ecore_imf_context_event_callback_call(imcontext->ctx,
                 ECORE_IMF_CALLBACK_PREEDIT_END, NULL);
     }
@@ -1369,8 +1362,6 @@ commit_preedit(WaylandIMContext *imcontext)
         char *commit_str = NULL;
         commit_str = strdup(imcontext->preedit_commit);
         clear_preedit(imcontext);
-        ecore_imf_context_commit_event_add(imcontext->ctx,
-                commit_str);
         ecore_imf_context_event_callback_call(imcontext->ctx,
                 ECORE_IMF_CALLBACK_COMMIT,
                 (void *)commit_str);
@@ -1900,7 +1891,6 @@ static void delete_surrounding_text(WaylandIMContext *imcontext, int index, int
     ev.offset = index;
     ev.n_chars = length;
 
-    ecore_imf_context_delete_surrounding_event_add(imcontext->ctx, ev.offset, ev.n_chars);
     ecore_imf_context_event_callback_call(imcontext->ctx, ECORE_IMF_CALLBACK_DELETE_SURROUNDING, &ev);
 }
 
@@ -1951,19 +1941,16 @@ text_input_preedit_string(void                 *data,
 
     if (preedit_changed) {
         if (!old_preedit) {
-            ecore_imf_context_preedit_start_event_add(imcontext->ctx);
             ecore_imf_context_event_callback_call(imcontext->ctx,
                     ECORE_IMF_CALLBACK_PREEDIT_START,
                     NULL);
         }
 
-        ecore_imf_context_preedit_changed_event_add(imcontext->ctx);
         ecore_imf_context_event_callback_call(imcontext->ctx,
                 ECORE_IMF_CALLBACK_PREEDIT_CHANGED,
                 NULL);
 
         if (imcontext->preedit_text && strlen(imcontext->preedit_text) == 0) {
-            ecore_imf_context_preedit_end_event_add(imcontext->ctx);
             ecore_imf_context_event_callback_call(imcontext->ctx,
                     ECORE_IMF_CALLBACK_PREEDIT_END,
                     NULL);
@@ -2594,19 +2581,16 @@ text_input_recapture_string(void                 *data,
 
     if (preedit_changed) {
         if (!old_preedit) {
-            ecore_imf_context_preedit_start_event_add(imcontext->ctx);
             ecore_imf_context_event_callback_call(imcontext->ctx,
                     ECORE_IMF_CALLBACK_PREEDIT_START,
                     NULL);
         }
 
-        ecore_imf_context_preedit_changed_event_add(imcontext->ctx);
         ecore_imf_context_event_callback_call(imcontext->ctx,
                 ECORE_IMF_CALLBACK_PREEDIT_CHANGED,
                 NULL);
 
         if (imcontext->preedit_text && strlen(imcontext->preedit_text) == 0) {
-            ecore_imf_context_preedit_end_event_add(imcontext->ctx);
             ecore_imf_context_event_callback_call(imcontext->ctx,
                     ECORE_IMF_CALLBACK_PREEDIT_END,
                     NULL);
@@ -2615,7 +2599,6 @@ text_input_recapture_string(void                 *data,
 
     // commit string
     if (commit && strlen(commit) != 0) {
-        ecore_imf_context_commit_event_add(imcontext->ctx, commit);
         ecore_imf_context_event_callback_call(imcontext->ctx, ECORE_IMF_CALLBACK_COMMIT, (void *)commit);
     }