summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChunEon Park <hermet@hermet.pe.kr>2013-09-29 17:30:55 +0900
committerChunEon Park <hermet@hermet.pe.kr>2013-09-29 17:31:56 +0900
commit3b6961e17542d8940d6de9a08b9b820f1fe7a5f7 (patch)
treecd40324fca1fc36a85c3f57f12aedab1dc0e3eb4
parent203b6295e930da66a05f76be9a058b556af2c711 (diff)
evas/canvas - code refactoring. more clean code.
-rw-r--r--src/lib/evas/canvas/evas_object_smart.c19
1 files changed, 7 insertions, 12 deletions
diff --git a/src/lib/evas/canvas/evas_object_smart.c b/src/lib/evas/canvas/evas_object_smart.c
index b2d54c8661..8f156c0088 100644
--- a/src/lib/evas/canvas/evas_object_smart.c
+++ b/src/lib/evas/canvas/evas_object_smart.c
@@ -1221,11 +1221,13 @@ _smart_members_changed_check(Evas_Object *eo_obj, Evas_Object_Protected_Data *ob
1221{ 1221{
1222 Evas_Object_Protected_Data *o2; 1222 Evas_Object_Protected_Data *o2;
1223 1223
1224 if (!obj->changed) return EINA_FALSE;
1225 if (!obj->smart.smart) return EINA_TRUE;
1226
1224 if (!evas_object_is_visible(eo_obj, obj) && 1227 if (!evas_object_is_visible(eo_obj, obj) &&
1225 !evas_object_was_visible(eo_obj, obj)) 1228 !evas_object_was_visible(eo_obj, obj))
1226 return EINA_FALSE; 1229 return EINA_FALSE;
1227 1230
1228 if (!obj->smart.smart) return EINA_TRUE;
1229 if (_evas_render_has_map(eo_obj, obj)) 1231 if (_evas_render_has_map(eo_obj, obj))
1230 { 1232 {
1231 if (((obj->changed_pchange) && (obj->changed_map)) || 1233 if (((obj->changed_pchange) && (obj->changed_map)) ||
@@ -1233,10 +1235,7 @@ _smart_members_changed_check(Evas_Object *eo_obj, Evas_Object_Protected_Data *ob
1233 } 1235 }
1234 1236
1235 EINA_INLIST_FOREACH(evas_object_smart_members_get_direct(eo_obj), o2) 1237 EINA_INLIST_FOREACH(evas_object_smart_members_get_direct(eo_obj), o2)
1236 { 1238 if (_smart_members_changed_check(o2->object, o2)) return EINA_TRUE;
1237 if (!o2->changed) continue;
1238 if (_smart_members_changed_check(o2->object, o2)) return EINA_TRUE;
1239 }
1240 1239
1241 return EINA_FALSE; 1240 return EINA_FALSE;
1242} 1241}
@@ -1246,18 +1245,14 @@ evas_object_smart_changed_get(Evas_Object *eo_obj)
1246{ 1245{
1247 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS); 1246 Evas_Object_Protected_Data *obj = eo_data_scope_get(eo_obj, EVAS_OBJ_CLASS);
1248 Evas_Object_Protected_Data *o2; 1247 Evas_Object_Protected_Data *o2;
1249 Eina_Bool changed = EINA_FALSE;
1250 1248
1251 if (!obj->is_smart) return obj->changed; 1249 if (!obj->is_smart) return obj->changed;
1252 if (obj->changed_color) return EINA_TRUE; 1250 if (obj->changed_color) return EINA_TRUE;
1253 1251
1254 EINA_INLIST_FOREACH(evas_object_smart_members_get_direct(eo_obj), o2) 1252 EINA_INLIST_FOREACH(evas_object_smart_members_get_direct(eo_obj), o2)
1255 { 1253 if (_smart_members_changed_check(o2->object, o2)) return EINA_TRUE;
1256 if (!o2->changed) continue; 1254
1257 changed = _smart_members_changed_check(o2->object, o2); 1255 return EINA_FALSE;
1258 if (changed) break;
1259 }
1260 return changed;
1261} 1256}
1262 1257
1263void 1258void