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

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

Issue 170863003: Removes #ash-enable-sticky-edges flag (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 10 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/ash_switches.cc ('k') | ash/wm/workspace/workspace_window_resizer_unittest.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ash/wm/workspace/workspace_window_resizer.cc
diff --git a/ash/wm/workspace/workspace_window_resizer.cc b/ash/wm/workspace/workspace_window_resizer.cc
index 357949c11596a645418426f8588b6dcfc4256c9a..c5d62c343a6a7f8728be246f96360c900c8c104a 100644
--- a/ash/wm/workspace/workspace_window_resizer.cc
+++ b/ash/wm/workspace/workspace_window_resizer.cc
@@ -111,12 +111,6 @@ namespace {
// Returns true if the window should stick to the edge.
bool ShouldStickToEdge(int distance_from_edge, int sticky_size) {
- if (CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kAshEnableStickyEdges)) {
- // TODO(varkha): Consider keeping snapping behavior for touch drag.
- return distance_from_edge < 0 &&
- distance_from_edge > -sticky_size;
- }
return distance_from_edge < sticky_size &&
distance_from_edge > -sticky_size * 2;
}
@@ -262,9 +256,6 @@ const int WorkspaceWindowResizer::kMinOnscreenHeight = 32;
const int WorkspaceWindowResizer::kScreenEdgeInset = 8;
// static
-const int WorkspaceWindowResizer::kStickyDistancePixels = 64;
-
-// static
WorkspaceWindowResizer* WorkspaceWindowResizer::instance_ = NULL;
// Represents the width or height of a window with constraints on its minimum
@@ -359,9 +350,6 @@ void WorkspaceWindowResizer::Drag(const gfx::Point& location_in_parent,
int sticky_size;
if (event_flags & ui::EF_CONTROL_DOWN) {
sticky_size = 0;
- } else if (CommandLine::ForCurrentProcess()->HasSwitch(
- switches::kAshEnableStickyEdges)) {
- sticky_size = kStickyDistancePixels;
} else if ((details().bounds_change & kBoundsChange_Resizes) &&
details().source == aura::client::WINDOW_MOVE_SOURCE_TOUCH) {
sticky_size = SnapSizer::kScreenEdgeInsetForTouchDrag;
« no previous file with comments | « ash/ash_switches.cc ('k') | ash/wm/workspace/workspace_window_resizer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698