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

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

Issue 9764008: Makes the launcher auto-hide for maximized windows. This turned out to (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Add null checks and cleanup Created 8 years, 9 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: ash/wm/workspace/snap_sizer.cc
diff --git a/ash/wm/workspace/snap_sizer.cc b/ash/wm/workspace/snap_sizer.cc
index d2641b08d4886e0b2faa561fe5b3f12db3a8d52c..8ee3e1f3fcdad918218454bcba1f6628be59f404 100644
--- a/ash/wm/workspace/snap_sizer.cc
+++ b/ash/wm/workspace/snap_sizer.cc
@@ -6,6 +6,7 @@
#include <cmath>
+#include "ash/screen_ash.h"
#include "ash/wm/window_resizer.h"
#include "ui/aura/window.h"
#include "ui/gfx/screen.h"
@@ -93,7 +94,7 @@ void SnapSizer::ChangeBounds(int x, int delta) {
}
gfx::Rect SnapSizer::GetTargetBounds() const {
- gfx::Rect work_area(gfx::Screen::GetMonitorWorkAreaNearestWindow(window_));
+ gfx::Rect work_area(ScreenAsh::GetUnmaximizedWorkAreaBounds(window_));
int y = WindowResizer::AlignToGridRoundUp(work_area.y(), grid_size_);
int max_y =
WindowResizer::AlignToGridRoundDown(work_area.bottom(), grid_size_);

Powered by Google App Engine
This is Rietveld 408576698