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

Unified Diff: webkit/tools/test_shell/webwidget_host_win.cc

Issue 11110004: Make gfx::Rect class operations consistently mutate the class they are called on. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: 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
« ui/gfx/rect_f.h ('K') | « webkit/tools/test_shell/webwidget_host_mac.mm ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/tools/test_shell/webwidget_host_win.cc
diff --git a/webkit/tools/test_shell/webwidget_host_win.cc b/webkit/tools/test_shell/webwidget_host_win.cc
index db5244ad3bc8dc41b2305060d8f4e619a015ccda..75fd90c85d2cd7b7ada728e4ad0adb0c41effff4 100644
--- a/webkit/tools/test_shell/webwidget_host_win.cc
+++ b/webkit/tools/test_shell/webwidget_host_win.cc
@@ -249,7 +249,7 @@ void WebWidgetHost::Paint() {
webwidget_->layout();
// Scroll the canvas if necessary
- scroll_rect_ = client_rect.Intersect(scroll_rect_);
+ scroll_rect_.Intersect(client_rect);
if (!scroll_rect_.IsEmpty()) {
skia::ScopedPlatformPaint scoped_platform_paint(canvas_.get());
HDC hdc = scoped_platform_paint.GetPlatformSurface();
@@ -265,7 +265,7 @@ void WebWidgetHost::Paint() {
// first time we call it. This is necessary because some WebCore rendering
// objects update their layout only when painted.
for (int i = 0; i < 2; ++i) {
- paint_rect_ = client_rect.Intersect(paint_rect_);
+ paint_rect_.Intersect(client_rect);
if (!paint_rect_.IsEmpty()) {
gfx::Rect rect(paint_rect_);
paint_rect_ = gfx::Rect();
« ui/gfx/rect_f.h ('K') | « webkit/tools/test_shell/webwidget_host_mac.mm ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698