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

Side by Side Diff: ash/wm/workspace/workspace_layout_manager2_unittest.cc

Issue 11085053: Improving window auto management between workspaces (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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/workspace/workspace_layout_manager.h" 5 #include "ash/wm/workspace/workspace_layout_manager.h"
6 6
7 #include "ash/shell.h" 7 #include "ash/shell.h"
8 #include "ash/test/ash_test_base.h" 8 #include "ash/test/ash_test_base.h"
9 #include "ash/wm/property_util.h" 9 #include "ash/wm/property_util.h"
10 #include "ash/wm/shelf_layout_manager.h" 10 #include "ash/wm/shelf_layout_manager.h"
11 #include "ash/wm/window_util.h" 11 #include "ash/wm/window_util.h"
12 #include "base/string_number_conversions.h"
12 #include "ui/aura/root_window.h" 13 #include "ui/aura/root_window.h"
13 #include "ui/aura/test/test_windows.h" 14 #include "ui/aura/test/test_windows.h"
14 #include "ui/aura/window.h" 15 #include "ui/aura/window.h"
15 #include "ui/gfx/insets.h" 16 #include "ui/gfx/insets.h"
16 17
17 namespace ash { 18 namespace ash {
18 19
19 namespace { 20 namespace {
20 21
21 class WorkspaceLayoutManager2Test : public test::AshTestBase { 22 class WorkspaceLayoutManager2Test : public test::AshTestBase {
(...skipping 106 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 gfx::Rect root_window_bounds = 129 gfx::Rect root_window_bounds =
129 ash::Shell::GetInstance()->GetPrimaryRootWindow()->bounds(); 130 ash::Shell::GetInstance()->GetPrimaryRootWindow()->bounds();
130 window_bounds.Offset(root_window_bounds.width(), root_window_bounds.height()); 131 window_bounds.Offset(root_window_bounds.width(), root_window_bounds.height());
131 ASSERT_FALSE(window_bounds.Intersects(root_window_bounds)); 132 ASSERT_FALSE(window_bounds.Intersects(root_window_bounds));
132 scoped_ptr<aura::Window> out_window(CreateTestWindow(window_bounds)); 133 scoped_ptr<aura::Window> out_window(CreateTestWindow(window_bounds));
133 EXPECT_EQ(window_bounds.size(), out_window->bounds().size()); 134 EXPECT_EQ(window_bounds.size(), out_window->bounds().size());
134 EXPECT_TRUE(out_window->bounds().Intersects(root_window_bounds)); 135 EXPECT_TRUE(out_window->bounds().Intersects(root_window_bounds));
135 } 136 }
136 137
137 } // namespace 138 } // namespace
138
139 } // namespace ash 139 } // namespace ash
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698