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

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

Issue 2823133002: Clean up some ash constants. (Closed)
Patch Set: ditto Created 3 years, 8 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/workspace_window_resizer_unittest.cc
diff --git a/ash/wm/workspace/workspace_window_resizer_unittest.cc b/ash/wm/workspace/workspace_window_resizer_unittest.cc
index 3fd046e3e223f3291e89bcd31f3c6b10da5bec01..8b85e3dbe8c510b098174810fcce516eec79838a 100644
--- a/ash/wm/workspace/workspace_window_resizer_unittest.cc
+++ b/ash/wm/workspace/workspace_window_resizer_unittest.cc
@@ -1025,19 +1025,11 @@ TEST_F(WorkspaceWindowResizerTest, SnapToEdge) {
resizer->Drag(CalculateDragPoint(*resizer, distance_to_right + 33, 0), 0);
EXPECT_EQ("513,112 320x160", window_->bounds().ToString());
- int auto_hidden_shelf_height = GetShelfConstant(SHELF_INSETS_FOR_AUTO_HIDE);
-
// And the bottom should snap too.
- resizer->Drag(
- CalculateDragPoint(*resizer, 0,
- distance_to_bottom - auto_hidden_shelf_height - 7),
- 0);
+ resizer->Drag(CalculateDragPoint(*resizer, 0, distance_to_bottom - 7), 0);
EXPECT_EQ(gfx::Rect(96, 440, 320, 160).ToString(),
window_->bounds().ToString());
- resizer->Drag(
- CalculateDragPoint(*resizer, 0,
- distance_to_bottom - auto_hidden_shelf_height + 15),
- 0);
+ resizer->Drag(CalculateDragPoint(*resizer, 0, distance_to_bottom + 15), 0);
EXPECT_EQ(gfx::Rect(96, 440, 320, 160).ToString(),
window_->bounds().ToString());
resizer->Drag(CalculateDragPoint(*resizer, 0, distance_to_bottom - 2 + 32),
@@ -1054,16 +1046,14 @@ TEST_F(WorkspaceWindowResizerTest, SnapToEdge) {
EXPECT_EQ("96,0 320x160", window_->bounds().ToString());
// And bottom/left should snap too.
- resizer->Drag(
- CalculateDragPoint(*resizer, 7 - distance_to_left,
- distance_to_bottom - auto_hidden_shelf_height - 7),
- 0);
+ resizer->Drag(CalculateDragPoint(*resizer, 7 - distance_to_left,
+ distance_to_bottom - 7),
+ 0);
EXPECT_EQ(gfx::Rect(0, 440, 320, 160).ToString(),
window_->bounds().ToString());
- resizer->Drag(
- CalculateDragPoint(*resizer, -15 - distance_to_left,
- distance_to_bottom - auto_hidden_shelf_height + 15),
- 0);
+ resizer->Drag(CalculateDragPoint(*resizer, -15 - distance_to_left,
+ distance_to_bottom + 15),
+ 0);
EXPECT_EQ(gfx::Rect(0, 440, 320, 160).ToString(),
window_->bounds().ToString());
// should move past snap points.
« no previous file with comments | « ash/wm/workspace/workspace_layout_manager_unittest.cc ('k') | chrome/browser/ui/apps/chrome_app_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698