summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYoungbok Shin <youngb.shin@samsung.com>2016-03-16 19:30:44 +0900
committerYoungbok Shin <youngb.shin@samsung.com>2016-03-16 19:30:44 +0900
commita73f121a5d1b9c5bae1612e9587094bcb873653c (patch)
treec96fb4e9e9075631a83fb693a00daf06697f9347
parent4c7f489e02a364d4c9c102f230c6d26a738b1256 (diff)
Label: Add non-editable/singleline label widget by default.
-rw-r--r--src/lib/elm_label.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/src/lib/elm_label.c b/src/lib/elm_label.c
index 378e16702..089f76e76 100644
--- a/src/lib/elm_label.c
+++ b/src/lib/elm_label.c
@@ -331,9 +331,14 @@ _elm_label_eo_base_constructor(Eo *obj, Elm_Label_Data *_pd EINA_UNUSED)
331EOLIAN static Eo * 331EOLIAN static Eo *
332_elm_label_eo_base_finalize(Eo *obj, Elm_Label_Data *_pd EINA_UNUSED) 332_elm_label_eo_base_finalize(Eo *obj, Elm_Label_Data *_pd EINA_UNUSED)
333{ 333{
334 if (!elm_layout_theme_set(obj, "entry", "base-noedit", elm_widget_style_get(obj))) 334 /* FIXME: It should be called when eo_add() is called for
335 CRI("Failed to set layout!"); 335 * improving performance. Elm label is singleline and non editable
336 elm_layout_text_set(obj, NULL, "<br>"); 336 * by default. The changing these properties not only change Edje,
337 * but also change flags inside of entry.
338 * So, we need to call entry APIs for changing its properties. */
339 elm_entry_editable_set(obj, EINA_FALSE);
340 elm_entry_single_line_set(obj, EINA_TRUE);
341
337 elm_layout_sizing_eval(obj); 342 elm_layout_sizing_eval(obj);
338 return obj; 343 return obj;
339} 344}