summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas/evas_map.c
diff options
context:
space:
mode:
authorChunEon Park <hermet@hermet.pe.kr>2014-01-06 13:54:58 +0900
committerChunEon Park <hermet@hermet.pe.kr>2014-01-06 13:54:58 +0900
commita76e751eb471359ae3693d5123182d7d6a397be4 (patch)
tree6ef9f58ee26fe403d811f25252cfcbf568678bd8 /src/lib/evas/canvas/evas_map.c
parent8dc6adbf9c42c353118b45ad2e524d6117a73fff (diff)
evas - fixed side effect caused by f4d24e962dba33bef8f990ce3359c06eed8771d0
since the map_changed is reset right after the map is updated, it could not decide to redraw the map surface properly. now map_update() returns the value to redraw the map surface properly.
Diffstat (limited to 'src/lib/evas/canvas/evas_map.c')
-rw-r--r--src/lib/evas/canvas/evas_map.c14
1 files changed, 10 insertions, 4 deletions
diff --git a/src/lib/evas/canvas/evas_map.c b/src/lib/evas/canvas/evas_map.c
index f10cde0..6ef034a 100644
--- a/src/lib/evas/canvas/evas_map.c
+++ b/src/lib/evas/canvas/evas_map.c
@@ -1217,7 +1217,11 @@ evas_map_util_clockwise_get(Evas_Map *m)
1217 return EINA_FALSE; 1217 return EINA_FALSE;
1218} 1218}
1219 1219
1220void 1220
1221/****************************************************************************/
1222/* If the return value is true, the map surface should be redrawn. */
1223/****************************************************************************/
1224Eina_Bool
1221evas_object_map_update(Evas_Object *eo_obj, 1225evas_object_map_update(Evas_Object *eo_obj,
1222 int x, int y, 1226 int x, int y,
1223 int imagew, int imageh, 1227 int imagew, int imageh,
@@ -1227,7 +1231,7 @@ evas_object_map_update(Evas_Object *eo_obj,
1227 const Evas_Map_Point *p, *p_end; 1231 const Evas_Map_Point *p, *p_end;
1228 RGBA_Map_Point *pts, *pt; 1232 RGBA_Map_Point *pts, *pt;
1229 1233
1230 if (!obj) return; 1234 if (!obj) return EINA_FALSE;
1231 if (obj->map->spans) 1235 if (obj->map->spans)
1232 { 1236 {
1233 if (obj->map->spans->x != x || obj->map->spans->y != y || 1237 if (obj->map->spans->x != x || obj->map->spans->y != y ||
@@ -1240,7 +1244,7 @@ evas_object_map_update(Evas_Object *eo_obj,
1240 obj->changed_map = EINA_TRUE; 1244 obj->changed_map = EINA_TRUE;
1241 } 1245 }
1242 1246
1243 if (!obj->changed_map) return; 1247 if (!obj->changed_map) return EINA_FALSE;
1244 1248
1245 if (obj->map->cur.map && obj->map->spans && obj->map->cur.map->count != obj->map->spans->count) 1249 if (obj->map->cur.map && obj->map->spans && obj->map->cur.map->count != obj->map->spans->count)
1246 { 1250 {
@@ -1264,7 +1268,7 @@ evas_object_map_update(Evas_Object *eo_obj,
1264 EINA_COW_WRITE_END(evas_object_map_cow, obj->map, map_write); 1268 EINA_COW_WRITE_END(evas_object_map_cow, obj->map, map_write);
1265 } 1269 }
1266 1270
1267 if (!obj->map->spans) return; 1271 if (!obj->map->spans) return EINA_FALSE;
1268 1272
1269 EINA_COW_WRITE_BEGIN(evas_object_map_cow, obj->map, Evas_Object_Map_Data, map_write) 1273 EINA_COW_WRITE_BEGIN(evas_object_map_cow, obj->map, Evas_Object_Map_Data, map_write)
1270 { 1274 {
@@ -1319,4 +1323,6 @@ evas_object_map_update(Evas_Object *eo_obj,
1319 // Request engine to update it's point 1323 // Request engine to update it's point
1320 1324
1321 obj->changed_map = EINA_FALSE; 1325 obj->changed_map = EINA_FALSE;
1326
1327 return obj->changed_pchange;
1322} 1328}