ctxpopup, entry: Check widget type by eo_isa not by evas_object_type

string compare.
This commit is contained in:
Daniel Juyung Seo 2014-01-13 23:14:44 +09:00
parent f1457a3540
commit 45ee408180
2 changed files with 4 additions and 4 deletions

View File

@ -230,7 +230,7 @@ _base_geometry_calc(Evas_Object *obj,
evas_object_geometry_get
(sd->parent, &hover_area.x, &hover_area.y, &hover_area.w,
&hover_area.h);
if (!strcmp(evas_object_type_get(sd->parent), "elm_win"))
if (sd->parent && eo_isa(sd->parent, ELM_OBJ_WIN_CLASS))
hover_area.x = hover_area.y = 0;
evas_object_geometry_get(obj, &pos.x, &pos.y, NULL, NULL);
@ -1257,7 +1257,7 @@ _hover_parent_set(Eo *obj, void *_pd, va_list *list)
//Update Background
evas_object_geometry_get(parent, &x, &y, &w, &h);
if (!strcmp(evas_object_type_get(parent), "elm_win"))
if (parent && eo_isa(parent, ELM_OBJ_WIN_CLASS))
x = y = 0;
evas_object_move(sd->bg, x, y);
evas_object_resize(sd->bg, w, h);

View File

@ -912,7 +912,7 @@ _elm_entry_smart_on_focus(Eo *obj, void *_pd EINA_UNUSED, va_list *list)
Elm_Entry_Smart_Data *sd = _pd;
top = elm_widget_top_get(obj);
if (!strcmp(evas_object_type_get(top), "elm_win"))
if (top && eo_isa(top, ELM_OBJ_WIN_CLASS))
top_is_win = EINA_TRUE;
if (!sd->editable) return;
@ -1597,7 +1597,7 @@ _mouse_up_cb(void *data,
top = elm_widget_top_get(data);
if (top)
{
if (!strcmp(evas_object_type_get(top), "elm_win"))
if (top && eo_isa(top, ELM_OBJ_WIN_CLASS))
top_is_win = EINA_TRUE;
if (top_is_win && sd->input_panel_enable && sd->input_panel_show_on_demand &&