Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(607)

Unified Diff: ui/compositor/layer.h

Issue 1080633009: ui: Clean up damaged rects and clear them after painting. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: ui/compositor/layer.h
diff --git a/ui/compositor/layer.h b/ui/compositor/layer.h
index 381e9829b3250a1207df29ff2a8cdaa969a4ff7c..bb8b1af6de89c7dd944136a3df2c4b080d88b62b 100644
--- a/ui/compositor/layer.h
+++ b/ui/compositor/layer.h
@@ -14,6 +14,7 @@
#include "base/message_loop/message_loop.h"
#include "cc/animation/animation_events.h"
#include "cc/animation/layer_animation_event_observer.h"
+#include "cc/base/region.h"
#include "cc/base/scoped_ptr_vector.h"
#include "cc/layers/content_layer_client.h"
#include "cc/layers/layer_client.h"
@@ -319,8 +320,9 @@ class COMPOSITOR_EXPORT Layer
// Uses damaged rectangles recorded in |damaged_region_| to invalidate the
// |cc_layer_|.
void SendDamagedRects();
+ void ClearDamagedRects();
- const SkRegion& damaged_region() const { return damaged_region_; }
+ const cc::Region& damaged_region() const { return damaged_region_; }
void CompleteAllAnimations();
@@ -459,9 +461,9 @@ class COMPOSITOR_EXPORT Layer
bool fills_bounds_opaquely_;
bool fills_bounds_completely_;
- // Union of damaged rects, in pixel coordinates, to be used when
- // compositor is ready to paint the content.
- SkRegion damaged_region_;
+ // Union of damaged rects, in layer space, to be used when compositor is ready
+ // to paint the content.
+ cc::Region damaged_region_;
int background_blur_radius_;

Powered by Google App Engine
This is Rietveld 408576698