woohyun pushed a commit to branch master. http://git.enlightenment.org/core/elementary.git/commit/?id=97972844257fd3ffc20a620844a540150def0cf9
commit 97972844257fd3ffc20a620844a540150def0cf9 Author: WooHyun Jung <wh0705.j...@samsung.com> Date: Mon Oct 21 20:59:43 2013 +0900 elementary/elm_entry.c : theme,changed smart callback can move the cursor position ! Thanks Daniel~ --- src/lib/elm_entry.c | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/src/lib/elm_entry.c b/src/lib/elm_entry.c index ed83299..088b2db 100644 --- a/src/lib/elm_entry.c +++ b/src/lib/elm_entry.c @@ -521,14 +521,13 @@ _elm_entry_smart_theme(Eo *obj, void *_pd, va_list *list) edje_object_part_text_input_panel_return_key_disabled_set (sd->entry_edje, "elm.text", sd->input_panel_return_key_disabled); + // elm_entry_cursor_pos_set -> cursor,changed -> widget_show_region_set + // -> smart_objects_calculate will call all smart calculate functions, + // and one of them can delete elm_entry. + evas_object_ref(obj); + if (sd->cursor_pos != 0) - { - // elm_entry_cursor_pos_set -> cursor,changed -> widget_show_region_set - // -> smart_objects_calculate will call all smart calculate functions, - // and one of them can delete elm_entry. - evas_object_ref(obj); - elm_entry_cursor_pos_set(obj, sd->cursor_pos); - } + elm_entry_cursor_pos_set(obj, sd->cursor_pos); if (elm_widget_focus_get(obj)) edje_object_signal_emit(sd->entry_edje, "elm,action,focus", "elm"); @@ -570,8 +569,7 @@ _elm_entry_smart_theme(Eo *obj, void *_pd, va_list *list) evas_object_smart_callback_call(obj, SIG_THEME_CHANGED, NULL); - if (sd->cursor_pos != 0) - evas_object_unref(obj); + evas_object_unref(obj); if (ret) *ret = EINA_TRUE; } --