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

Side by Side Diff: ash/wm/custom_frame_view_ash_unittest.cc

Issue 22793011: ash:Shelf - Enable Alternate Shelf and Side Shelf by default. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 4 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ash/wm/custom_frame_view_ash.h" 5 #include "ash/wm/custom_frame_view_ash.h"
6 6
7 #include "ash/ash_switches.h"
James Cook 2013/08/22 00:19:12 Is this needed?
Harry McCleave 2013/08/27 00:37:00 Done.
7 #include "ash/shell.h" 8 #include "ash/shell.h"
8 #include "ash/test/ash_test_base.h" 9 #include "ash/test/ash_test_base.h"
9 #include "ash/wm/maximize_bubble_controller.h" 10 #include "ash/wm/maximize_bubble_controller.h"
10 #include "ash/wm/property_util.h" 11 #include "ash/wm/property_util.h"
11 #include "ash/wm/window_util.h" 12 #include "ash/wm/window_util.h"
12 #include "ash/wm/workspace/frame_maximize_button.h" 13 #include "ash/wm/workspace/frame_maximize_button.h"
13 #include "ash/wm/workspace/snap_sizer.h" 14 #include "ash/wm/workspace/snap_sizer.h"
14 #include "base/command_line.h" 15 #include "base/command_line.h"
15 #include "ui/aura/client/aura_constants.h" 16 #include "ui/aura/client/aura_constants.h"
16 #include "ui/aura/client/focus_client.h" 17 #include "ui/aura/client/focus_client.h"
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
260 end.Offset(40, 0); 261 end.Offset(40, 0);
261 generator.GestureScrollSequence(center, end, 262 generator.GestureScrollSequence(center, end,
262 base::TimeDelta::FromMilliseconds(100), 263 base::TimeDelta::FromMilliseconds(100),
263 3); 264 3);
264 RunAllPendingInMessageLoop(); 265 RunAllPendingInMessageLoop();
265 266
266 EXPECT_FALSE(ash::wm::IsWindowMaximized(window)); 267 EXPECT_FALSE(ash::wm::IsWindowMaximized(window));
267 EXPECT_FALSE(ash::wm::IsWindowMinimized(window)); 268 EXPECT_FALSE(ash::wm::IsWindowMinimized(window));
268 // This is a short resizing distance and different touch behavior 269 // This is a short resizing distance and different touch behavior
269 // applies which leads in half of the screen being used. 270 // applies which leads in half of the screen being used.
270 EXPECT_EQ("400,0 400x552", window->bounds().ToString()); 271 EXPECT_EQ("400,0 400x553", window->bounds().ToString());
271 } 272 }
272 273
273 // Snap left. 274 // Snap left.
274 { 275 {
275 center = view->GetBoundsInScreen().CenterPoint(); 276 center = view->GetBoundsInScreen().CenterPoint();
276 gfx::Point end = center; 277 gfx::Point end = center;
277 end.Offset(-40, 0); 278 end.Offset(-40, 0);
278 generator.GestureScrollSequence(center, end, 279 generator.GestureScrollSequence(center, end,
279 base::TimeDelta::FromMilliseconds(100), 280 base::TimeDelta::FromMilliseconds(100),
280 3); 281 3);
(...skipping 581 matching lines...) Expand 10 before | Expand all | Expand 10 after
862 863
863 // Check that there was no size change. 864 // Check that there was no size change.
864 EXPECT_EQ(widget->GetWindowBoundsInScreen().size().ToString(), 865 EXPECT_EQ(widget->GetWindowBoundsInScreen().size().ToString(),
865 window_position.size().ToString()); 866 window_position.size().ToString());
866 // Check that there is no phantom window left open. 867 // Check that there is no phantom window left open.
867 EXPECT_FALSE(maximize_button->phantom_window_open()); 868 EXPECT_FALSE(maximize_button->phantom_window_open());
868 } 869 }
869 870
870 } // namespace internal 871 } // namespace internal
871 } // namespace ash 872 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698