| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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_controller.h" | 5 #include "ash/wm/workspace_controller.h" |
| 6 | 6 |
| 7 #include <map> | 7 #include <map> |
| 8 | 8 |
| 9 #include "ash/root_window_controller.h" | 9 #include "ash/root_window_controller.h" |
| 10 #include "ash/screen_util.h" | 10 #include "ash/screen_util.h" |
| (...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 121 aura::Window* CreateTestPanel(aura::WindowDelegate* delegate, | 121 aura::Window* CreateTestPanel(aura::WindowDelegate* delegate, |
| 122 const gfx::Rect& bounds) { | 122 const gfx::Rect& bounds) { |
| 123 aura::Window* window = CreateTestWindowInShellWithDelegateAndType( | 123 aura::Window* window = CreateTestWindowInShellWithDelegateAndType( |
| 124 delegate, | 124 delegate, |
| 125 ui::wm::WINDOW_TYPE_PANEL, | 125 ui::wm::WINDOW_TYPE_PANEL, |
| 126 0, | 126 0, |
| 127 bounds); | 127 bounds); |
| 128 test::TestShelfDelegate* shelf_delegate = | 128 test::TestShelfDelegate* shelf_delegate = |
| 129 test::TestShelfDelegate::instance(); | 129 test::TestShelfDelegate::instance(); |
| 130 shelf_delegate->AddShelfItem(window); | 130 shelf_delegate->AddShelfItem(window); |
| 131 PanelLayoutManager* manager = static_cast<PanelLayoutManager*>( | 131 PanelLayoutManager* manager = |
| 132 Shell::GetContainer(window->GetRootWindow(), | 132 PanelLayoutManager::Get(wm::WmWindowAura::Get(window)); |
| 133 kShellWindowId_PanelContainer)->layout_manager()); | |
| 134 manager->Relayout(); | 133 manager->Relayout(); |
| 135 return window; | 134 return window; |
| 136 } | 135 } |
| 137 | 136 |
| 138 aura::Window* GetDesktop() { | 137 aura::Window* GetDesktop() { |
| 139 return Shell::GetContainer(Shell::GetPrimaryRootWindow(), | 138 return Shell::GetContainer(Shell::GetPrimaryRootWindow(), |
| 140 kShellWindowId_DefaultContainer); | 139 kShellWindowId_DefaultContainer); |
| 141 } | 140 } |
| 142 | 141 |
| 143 gfx::Rect GetFullscreenBounds(aura::Window* window) { | 142 gfx::Rect GetFullscreenBounds(aura::Window* window) { |
| (...skipping 1465 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1609 ui::EventTimeForNow()); | 1608 ui::EventTimeForNow()); |
| 1610 target = targeter->FindTargetForEvent(root, &touch); | 1609 target = targeter->FindTargetForEvent(root, &touch); |
| 1611 if (points[i].is_target_hit) | 1610 if (points[i].is_target_hit) |
| 1612 EXPECT_EQ(window.get(), target); | 1611 EXPECT_EQ(window.get(), target); |
| 1613 else | 1612 else |
| 1614 EXPECT_NE(window.get(), target); | 1613 EXPECT_NE(window.get(), target); |
| 1615 } | 1614 } |
| 1616 } | 1615 } |
| 1617 | 1616 |
| 1618 } // namespace ash | 1617 } // namespace ash |
| OLD | NEW |