From 7ad6c34a2c426b602fdb57897006a77d5f3f5c2d Mon Sep 17 00:00:00 2001 From: Li Zhang Date: Thu, 24 Mar 2016 17:51:50 +0800 Subject: [PATCH] Add ECORE_IMF_CALLBACK_DELETE_SURROUNDING Change-Id: I0e1ab14736a3d3849becb7cbeea81fe7b61053b7 --- src/modules/ecore_imf/wayland/wayland_imcontext.c | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/src/modules/ecore_imf/wayland/wayland_imcontext.c b/src/modules/ecore_imf/wayland/wayland_imcontext.c index 7b35a13150..06fddddadf 100644 --- a/src/modules/ecore_imf/wayland/wayland_imcontext.c +++ b/src/modules/ecore_imf/wayland/wayland_imcontext.c @@ -458,13 +458,16 @@ text_input_delete_surrounding_text(void *data, uint32_t length) { WaylandIMContext *imcontext = (WaylandIMContext *)data; - + Ecore_IMF_Event_Delete_Surrounding ev; EINA_LOG_DOM_INFO(_ecore_imf_wayland_log_dom, "delete surrounding text (index: %d, length: %u)", index, length); - imcontext->pending_commit.delete_index = index; - imcontext->pending_commit.delete_length = length; + imcontext->pending_commit.delete_index = ev.offset = index; + imcontext->pending_commit.delete_length = 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); } static void