From be424508159efa3a3832803e54fba4627acbde34 Mon Sep 17 00:00:00 2001 From: Jeonghyun Yun Date: Thu, 3 Nov 2011 03:59:14 -0400 Subject: [PATCH] els_icon exception handling code added --- src/lib/els_icon.c | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/src/lib/els_icon.c b/src/lib/els_icon.c index 43307c9..83b3af8 100755 --- a/src/lib/els_icon.c +++ b/src/lib/els_icon.c @@ -188,10 +188,13 @@ _els_smart_icon_size_get(const Evas_Object *obj, int *w, int *h) Smart_Data *sd; int tw, th; int cw, ch; + const char *type; sd = evas_object_smart_data_get(obj); if (!sd) return; - if (!strcmp(evas_object_type_get(sd->obj), "edje")) + type = evas_object_type_get(sd->obj); + if (!type) return; + if (!strcmp(type, "edje")) edje_object_size_min_get(sd->obj, &tw, &th); else evas_object_image_size_get(sd->obj, &tw, &th); @@ -473,13 +476,16 @@ static void _smart_reconfigure(Smart_Data *sd) { Evas_Coord x, y, w, h; + const char *type; if (!sd->obj) return; w = sd->w; h = sd->h; - if (!strcmp(evas_object_type_get(sd->obj), "edje")) + type = evas_object_type_get(sd->obj); + if (!type) return; + if (!strcmp(type, "edje")) { x = sd->x; y = sd->y; -- 2.7.4