| 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/root_window_controller.h" | 5 #include "ash/root_window_controller.h" |
| 6 | 6 |
| 7 #include <queue> | 7 #include <queue> |
| 8 #include <vector> | 8 #include <vector> |
| 9 | 9 |
| 10 #include "ash/aura/aura_layout_manager_adapter.h" | 10 #include "ash/aura/aura_layout_manager_adapter.h" |
| (...skipping 460 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 471 if (shelf_) | 471 if (shelf_) |
| 472 return; | 472 return; |
| 473 ShelfView* shelf_view = shelf_widget_->CreateShelfView(); | 473 ShelfView* shelf_view = shelf_widget_->CreateShelfView(); |
| 474 | 474 |
| 475 shelf_.reset( | 475 shelf_.reset( |
| 476 new Shelf(wm_shelf_aura_.get(), shelf_view, shelf_widget_.get())); | 476 new Shelf(wm_shelf_aura_.get(), shelf_view, shelf_widget_.get())); |
| 477 shelf_widget_->set_shelf(shelf_.get()); | 477 shelf_widget_->set_shelf(shelf_.get()); |
| 478 // Must be initialized before the delegate is notified because the delegate | 478 // Must be initialized before the delegate is notified because the delegate |
| 479 // may try to access the WmShelf. | 479 // may try to access the WmShelf. |
| 480 wm_shelf_aura_->SetShelf(shelf_.get()); | 480 wm_shelf_aura_->SetShelf(shelf_.get()); |
| 481 WmShell::Get()->shelf_delegate()->OnShelfCreated(shelf_.get()); | 481 WmShell::Get()->shelf_delegate()->OnShelfCreated(wm_shelf_aura_.get()); |
| 482 | 482 |
| 483 if (panel_layout_manager_) | 483 if (panel_layout_manager_) |
| 484 panel_layout_manager_->SetShelf(wm_shelf_aura_.get()); | 484 panel_layout_manager_->SetShelf(wm_shelf_aura_.get()); |
| 485 if (docked_layout_manager_) { | 485 if (docked_layout_manager_) { |
| 486 docked_layout_manager_->SetShelf(wm_shelf_aura_.get()); | 486 docked_layout_manager_->SetShelf(wm_shelf_aura_.get()); |
| 487 if (shelf_widget_->shelf_layout_manager()) | 487 if (shelf_widget_->shelf_layout_manager()) |
| 488 docked_layout_manager_->AddObserver( | 488 docked_layout_manager_->AddObserver( |
| 489 shelf_widget_->shelf_layout_manager()); | 489 shelf_widget_->shelf_layout_manager()); |
| 490 } | 490 } |
| 491 | 491 |
| (...skipping 467 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 959 aura::Window* primary_root_window = Shell::GetInstance() | 959 aura::Window* primary_root_window = Shell::GetInstance() |
| 960 ->window_tree_host_manager() | 960 ->window_tree_host_manager() |
| 961 ->GetPrimaryRootWindow(); | 961 ->GetPrimaryRootWindow(); |
| 962 return GetRootWindowSettings(primary_root_window)->controller; | 962 return GetRootWindowSettings(primary_root_window)->controller; |
| 963 } | 963 } |
| 964 | 964 |
| 965 return GetRootWindowSettings(root_window)->controller; | 965 return GetRootWindowSettings(root_window)->controller; |
| 966 } | 966 } |
| 967 | 967 |
| 968 } // namespace ash | 968 } // namespace ash |
| OLD | NEW |