forked from enlightenment/enlightenment
remove some infintie loops in entry where is resizes to the same size
and sets the same3 text again and again. SVN revision: 79556
This commit is contained in:
parent
d6367c3601
commit
4d880b56ec
|
@ -113,6 +113,8 @@ e_entry_text_set(Evas_Object *entry, const char *_text)
|
||||||
text = evas_textblock_text_utf8_to_markup(
|
text = evas_textblock_text_utf8_to_markup(
|
||||||
edje_object_part_object_get(sd->entry_object, ENTRY_PART_NAME),
|
edje_object_part_object_get(sd->entry_object, ENTRY_PART_NAME),
|
||||||
_text);
|
_text);
|
||||||
|
if ((text) && (_text) && (!strcmp(text, _text))) return;
|
||||||
|
if ((!text) && (!_text)) return;
|
||||||
edje_object_part_text_set(sd->entry_object, ENTRY_PART_NAME, text);
|
edje_object_part_text_set(sd->entry_object, ENTRY_PART_NAME, text);
|
||||||
evas_object_smart_callback_call(entry, "changed", NULL);
|
evas_object_smart_callback_call(entry, "changed", NULL);
|
||||||
if (text)
|
if (text)
|
||||||
|
@ -631,7 +633,7 @@ static void
|
||||||
_entry_recalc_size(Evas_Object *object)
|
_entry_recalc_size(Evas_Object *object)
|
||||||
{
|
{
|
||||||
E_Entry_Smart_Data *sd;
|
E_Entry_Smart_Data *sd;
|
||||||
Evas_Coord vw, vh, w, h;
|
Evas_Coord vw, vh, w, h, pw = 0, ph = 0;
|
||||||
|
|
||||||
if ((!object) || !(sd = evas_object_smart_data_get(object)))
|
if ((!object) || !(sd = evas_object_smart_data_get(object)))
|
||||||
return;
|
return;
|
||||||
|
@ -639,7 +641,8 @@ _entry_recalc_size(Evas_Object *object)
|
||||||
e_scrollframe_child_viewport_size_get(sd->scroll_object, &vw, &vh);
|
e_scrollframe_child_viewport_size_get(sd->scroll_object, &vw, &vh);
|
||||||
w = (sd->min_width < vw) ? vw : sd->min_width;
|
w = (sd->min_width < vw) ? vw : sd->min_width;
|
||||||
h = (sd->height < vh) ? vh : sd->height;
|
h = (sd->height < vh) ? vh : sd->height;
|
||||||
|
evas_object_geometry_get(sd->entry_object, NULL, NULL, &pw, &ph);
|
||||||
|
if ((w == pw) && (h == ph)) return;
|
||||||
evas_object_resize(sd->entry_object, w, h);
|
evas_object_resize(sd->entry_object, w, h);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue