From f9deaa9be9ac057c67b7b866434595411a8ab923 Mon Sep 17 00:00:00 2001 From: Daniel Hirt Date: Mon, 11 Jul 2016 11:18:19 +0000 Subject: [PATCH] Canvas text: add "changed" event We need to keep track on changes of content. --- src/lib/evas/canvas/efl_canvas_text.eo | 3 +++ src/lib/evas/canvas/evas_object_textblock.c | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/lib/evas/canvas/efl_canvas_text.eo b/src/lib/evas/canvas/efl_canvas_text.eo index 9d87467..a3675e9 100644 --- a/src/lib/evas/canvas/efl_canvas_text.eo +++ b/src/lib/evas/canvas/efl_canvas_text.eo @@ -303,4 +303,7 @@ class Efl.Canvas.Text (Efl.Canvas.Object, Efl.Text) Efl.Text.text.set; Efl.Text.text.get; } + events { + changed; [[The content (text or annotations) have changed.]] + } } diff --git a/src/lib/evas/canvas/evas_object_textblock.c b/src/lib/evas/canvas/evas_object_textblock.c index 0ab3162..66f8cf9 100644 --- a/src/lib/evas/canvas/evas_object_textblock.c +++ b/src/lib/evas/canvas/evas_object_textblock.c @@ -13963,13 +13963,13 @@ _efl_canvas_text_range_annotations_get(Eo *eo_obj EINA_UNUSED, Efl_Canvas_Text_D } EOLIAN static Efl_Canvas_Text_Annotation * -_efl_canvas_text_cursor_object_item_insert(Eo *cur_obj, +_efl_canvas_text_cursor_object_item_insert(Eo *cur_obj EINA_UNUSED, Efl_Canvas_Text_Cursor_Data *cur, const char *format) { Efl_Canvas_Text_Data *o = eo_data_scope_get(cur->obj, MY_CLASS); Efl_Canvas_Text_Annotation *ret = _textblock_annotation_insert(cur->obj, o, cur, cur, format, EINA_TRUE); - eo_event_callback_call(cur_obj, EFL_CANVAS_TEXT_CURSOR_EVENT_CHANGED, NULL); + eo_event_callback_call(cur->obj, EFL_CANVAS_TEXT_EVENT_CHANGED, NULL); return ret; } -- 2.7.4