changeset 531:1ad6c6192a80 Android_Skia

Skip root coord when propagate dirty area to parent cached
author Thinker K.F. Li <thinker@branda.to>
date Fri, 25 Dec 2009 11:13:21 +0800
parents cd41d9033567
children 5711059b9642
files src/redraw_man.c
diffstat 1 files changed, 7 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/src/redraw_man.c	Fri Dec 25 00:27:19 2009 +0800
+++ b/src/redraw_man.c	Fri Dec 25 11:13:21 2009 +0800
@@ -1845,9 +1845,10 @@
     dirty_coords = rdman->dirty_coords.ds;
     for(i = 0; i < n_dirty_coords; i++) {
 	coord = dirty_coords[i];
-	if(coord_get_flags(coord, COF_OWN_CANVAS)) {
-	    add_dirty_area(rdman, coord, coord->cur_area);
-	    add_dirty_area(rdman, coord, coord->last_area);
+	if(coord_get_flags(coord, COF_OWN_CANVAS) &&
+	   !coord_is_root(coord)) {
+	    add_dirty_area(rdman, coord->parent, coord->cur_area);
+	    add_dirty_area(rdman, coord->parent, coord->last_area);
 	}
     }
 
@@ -1915,6 +1916,9 @@
     if(r != OK)
 	return ERR;
 
+    /* Zeroing must be performed after clearing to get latest position
+     * of shapes for computing new bounding box
+     */
     r = add_rdman_zeroing_coords(rdman);
     if(r != OK)
 	return ERR;