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

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

Issue 10918077: Adding proper dragging behavior for L/R maximized windows. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: It looks like if git merged wrong here... Created 8 years, 3 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_resizer.cc ('k') | ash/wm/workspace/workspace_window_resizer.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 c874f6ea006ed59e31120ebfe7a1efab524485d5..735b1a670d01198b2a365d343625f360f72e1d71 100644
--- a/ash/wm/workspace/frame_maximize_button.cc
+++ b/ash/wm/workspace/frame_maximize_button.cc
@@ -553,9 +553,12 @@ MaximizeBubbleFrameState
gfx::Rect screen = gfx::Screen::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
+ // treat as no special state.
+ if (bounds.y() != screen.y() || bounds.height() != screen.height())
+ return FRAME_STATE_NONE;
+
// We have to be in a maximize mode at this point.
- DCHECK(bounds.y() == screen.y());
- DCHECK(bounds.height() >= screen.height());
if (bounds.x() == screen.x())
return FRAME_STATE_SNAP_LEFT;
if (bounds.right() == screen.right())
« no previous file with comments | « ash/wm/window_resizer.cc ('k') | ash/wm/workspace/workspace_window_resizer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698