Fix and expose more of the e_entry api. it works now.
SVN revision: 17093
This commit is contained in:
parent
7712947919
commit
4a48feb35b
|
@ -91,6 +91,117 @@ Evas_Object *e_entry_add (Evas *evas)
|
|||
return evas_object_smart_add(evas, e_entry_smart);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_text_set (Evas_Object *entry, const char *text)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_text_set (e_entry_sd->entry_object, text);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_text_insert (Evas_Object *entry, const char *text)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_insert (e_entry_sd->entry_object, text);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_delete_char_before(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_delete_char_before (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_delete_char_after(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_delete_char_after (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_cursor_move_at_start(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_cursor_move_at_start (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_cursor_move_at_end(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_cursor_move_at_end (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_cursor_move_left(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_cursor_move_left (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_cursor_move_right(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_cursor_move_right (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_cursor_show(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_cursor_show (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
void
|
||||
e_entry_cursor_hide(Evas_Object *entry)
|
||||
{
|
||||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!entry || !(e_entry_sd = evas_object_smart_data_get(entry)))
|
||||
return;
|
||||
|
||||
e_editable_text_cursor_hide (e_entry_sd->entry_object);
|
||||
}
|
||||
|
||||
|
||||
static void _e_entry_smart_add(Evas_Object *object)
|
||||
{
|
||||
Evas *evas;
|
||||
|
@ -122,7 +233,11 @@ static void _e_entry_smart_del(Evas_Object *object)
|
|||
E_Entry_Smart_Data *e_entry_sd;
|
||||
|
||||
if (!object || !(e_entry_sd = evas_object_smart_data_get(object)))
|
||||
return;
|
||||
return;
|
||||
|
||||
evas_object_del (e_entry_sd->entry_object);
|
||||
evas_object_del (e_entry_sd->edje_object);
|
||||
E_FREE (e_entry_sd);
|
||||
}
|
||||
|
||||
static void _e_entry_smart_raise(Evas_Object *object)
|
||||
|
|
|
@ -17,3 +17,16 @@ void e_editable_text_cursor_show(Evas_Object *object);
|
|||
void e_editable_text_cursor_hide(Evas_Object *object);
|
||||
|
||||
Evas_Object *e_entry_add(Evas *evas);
|
||||
void e_entry_text_set (Evas_Object *entry, const char *text);
|
||||
void e_entry_text_insert (Evas_Object *entry, const char *text);
|
||||
void e_entry_delete_char_before(Evas_Object *object);
|
||||
void e_entry_delete_char_after(Evas_Object *object);
|
||||
void e_entry_cursor_move_at_start(Evas_Object *object);
|
||||
void e_entry_cursor_move_at_end(Evas_Object *object);
|
||||
void e_entry_cursor_move_left(Evas_Object *object);
|
||||
void e_entry_cursor_move_right(Evas_Object *object);
|
||||
void e_entry_cursor_show(Evas_Object *object);
|
||||
void e_entry_cursor_hide(Evas_Object *object);
|
||||
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue