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

Unified Diff: ash/wm/partial_screenshot_view.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: cc/ fixes 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
« no previous file with comments | « ash/wm/base_layout_manager.cc ('k') | ash/wm/shelf_layout_manager.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/partial_screenshot_view.cc
diff --git a/ash/wm/partial_screenshot_view.cc b/ash/wm/partial_screenshot_view.cc
index 2c3e09dcb906a0ec0c920f0cd9ae0c9630065f50..dd0bd1da0ac94148cada909d418ff7ac6b6692d5 100644
--- a/ash/wm/partial_screenshot_view.cc
+++ b/ash/wm/partial_screenshot_view.cc
@@ -121,8 +121,10 @@ void PartialScreenshotView::OnMouseReleased(const ui::MouseEvent& event) {
is_dragging_ = false;
if (screenshot_delegate_) {
aura::RootWindow *root_window = Shell::GetPrimaryRootWindow();
+ gfx::Rect root_window_screenshot_rect = root_window->bounds();
+ root_window_screenshot_rect.Intersect(GetScreenshotRect());
screenshot_delegate_->HandleTakePartialScreenshot(
- root_window, root_window->bounds().Intersect(GetScreenshotRect()));
+ root_window, root_window_screenshot_rect);
}
}
« no previous file with comments | « ash/wm/base_layout_manager.cc ('k') | ash/wm/shelf_layout_manager.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698