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

Unified Diff: content/common/gpu/image_transport_surface.cc

Issue 11270042: Add non-member non-mutating methods for common gfx::Rect operations. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebased Created 8 years, 2 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: content/common/gpu/image_transport_surface.cc
diff --git a/content/common/gpu/image_transport_surface.cc b/content/common/gpu/image_transport_surface.cc
index 47bb204d7d225474af46f82affacd7ae222385f9..d5c1affed3d9d7bbd0385ac8c0fad46f87164900 100644
--- a/content/common/gpu/image_transport_surface.cc
+++ b/content/common/gpu/image_transport_surface.cc
@@ -32,8 +32,8 @@ void ImageTransportSurface::GetRegionsToCopy(
const gfx::Rect& previous_damage_rect,
const gfx::Rect& new_damage_rect,
std::vector<gfx::Rect>* regions) {
- gfx::Rect intersection = previous_damage_rect;
- intersection.Intersect(new_damage_rect);
+ gfx::Rect intersection =
+ gfx::IntersectRects(previous_damage_rect, new_damage_rect);
if (intersection.IsEmpty()) {
regions->push_back(previous_damage_rect);

Powered by Google App Engine
This is Rietveld 408576698