OLD | NEW |
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/shelf_layout_manager.h" | 5 #include "ash/wm/shelf_layout_manager.h" |
6 | 6 |
7 #include "ash/accelerators/accelerator_controller.h" | 7 #include "ash/accelerators/accelerator_controller.h" |
8 #include "ash/accelerators/accelerator_table.h" | 8 #include "ash/accelerators/accelerator_table.h" |
9 #include "ash/ash_switches.h" | 9 #include "ash/ash_switches.h" |
10 #include "ash/display/display_manager.h" | 10 #include "ash/display/display_manager.h" |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 | 163 |
164 void UpdateAutoHideStateNow() { | 164 void UpdateAutoHideStateNow() { |
165 GetShelfLayoutManager()->UpdateAutoHideStateNow(); | 165 GetShelfLayoutManager()->UpdateAutoHideStateNow(); |
166 } | 166 } |
167 | 167 |
168 aura::Window* CreateTestWindow() { | 168 aura::Window* CreateTestWindow() { |
169 aura::Window* window = new aura::Window(NULL); | 169 aura::Window* window = new aura::Window(NULL); |
170 window->SetProperty(aura::client::kShowStateKey, ui::SHOW_STATE_NORMAL); | 170 window->SetProperty(aura::client::kShowStateKey, ui::SHOW_STATE_NORMAL); |
171 window->SetType(aura::client::WINDOW_TYPE_NORMAL); | 171 window->SetType(aura::client::WINDOW_TYPE_NORMAL); |
172 window->Init(ui::LAYER_TEXTURED); | 172 window->Init(ui::LAYER_TEXTURED); |
173 window->SetParent(NULL); | 173 AddToRootWindow(window); |
174 return window; | 174 return window; |
175 } | 175 } |
176 | 176 |
177 // Overridden from AshTestBase: | 177 // Overridden from AshTestBase: |
178 virtual void SetUp() OVERRIDE { | 178 virtual void SetUp() OVERRIDE { |
179 CommandLine::ForCurrentProcess()->AppendSwitch( | 179 CommandLine::ForCurrentProcess()->AppendSwitch( |
180 ash::switches::kAshEnableTrayDragging); | 180 ash::switches::kAshEnableTrayDragging); |
181 test::AshTestBase::SetUp(); | 181 test::AshTestBase::SetUp(); |
182 } | 182 } |
183 private: | 183 private: |
(...skipping 788 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
972 EXPECT_TRUE(status_area_widget->IsMessageBubbleShown()); | 972 EXPECT_TRUE(status_area_widget->IsMessageBubbleShown()); |
973 } else { | 973 } else { |
974 EXPECT_FALSE(shelf->IsVisible()); | 974 EXPECT_FALSE(shelf->IsVisible()); |
975 EXPECT_FALSE(status_area_widget->IsMessageBubbleShown()); | 975 EXPECT_FALSE(status_area_widget->IsMessageBubbleShown()); |
976 } | 976 } |
977 } | 977 } |
978 } | 978 } |
979 | 979 |
980 } // namespace internal | 980 } // namespace internal |
981 } // namespace ash | 981 } // namespace ash |
OLD | NEW |