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

Unified Diff: ash/wm/workspace/frame_maximize_button.cc

Issue 11030017: Add context to gfx::Screen calls in support of simultaneous desktop+ash (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix new addition 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/window_util.cc ('k') | ash/wm/workspace/multi_window_resize_controller.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/workspace/frame_maximize_button.cc
diff --git a/ash/wm/workspace/frame_maximize_button.cc b/ash/wm/workspace/frame_maximize_button.cc
index 697cc73c96689d2748442eac9a1e0517424eca33..76415d05738331cd4c6726d424ece968ed645f11 100644
--- a/ash/wm/workspace/frame_maximize_button.cc
+++ b/ash/wm/workspace/frame_maximize_button.cc
@@ -236,7 +236,7 @@ void FrameMaximizeButton::OnMouseExited(const ui::MouseEvent& event) {
// within the bubble.
if (!is_snap_enabled_ && maximizer_.get()) {
if (maximizer_->GetBubbleWindow()) {
- gfx::Point screen_location = gfx::Screen::GetCursorScreenPoint();
+ gfx::Point screen_location = Shell::GetScreen()->GetCursorScreenPoint();
if (!maximizer_->GetBubbleWindow()->GetBoundsInScreen().Contains(
screen_location)) {
maximizer_.reset();
@@ -561,7 +561,7 @@ MaximizeBubbleFrameState
return FRAME_STATE_FULL;
// For Left/right maximize we need to check the dimensions.
gfx::Rect bounds = frame_->GetWidget()->GetWindowBoundsInScreen();
- gfx::Rect screen = gfx::Screen::GetDisplayMatching(bounds).work_area();
+ gfx::Rect screen = Shell::GetScreen()->GetDisplayMatching(bounds).work_area();
if (bounds.width() < (screen.width() * kMinSnapSizePercent) / 100)
return FRAME_STATE_NONE;
// We might still have a horizontally filled window at this point which we
« no previous file with comments | « ash/wm/window_util.cc ('k') | ash/wm/workspace/multi_window_resize_controller.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698