| Index: ash/mus/root_window_controller.cc
|
| diff --git a/ash/mus/root_window_controller.cc b/ash/mus/root_window_controller.cc
|
| index 887092f8bf684dfc5420f2ff59a5310547ba00d4..42b0f049b913f37c5dba993da7a17064e1b8826c 100644
|
| --- a/ash/mus/root_window_controller.cc
|
| +++ b/ash/mus/root_window_controller.cc
|
| @@ -14,7 +14,9 @@
|
| #include <vector>
|
|
|
| #include "ash/common/root_window_controller_common.h"
|
| +#include "ash/common/session/session_state_delegate.h"
|
| #include "ash/common/shell_window_ids.h"
|
| +#include "ash/common/system/status_area_widget.h"
|
| #include "ash/common/wm/always_on_top_controller.h"
|
| #include "ash/common/wm/container_finder.h"
|
| #include "ash/common/wm/dock/docked_window_layout_manager.h"
|
| @@ -30,7 +32,6 @@
|
| #include "ash/mus/property_util.h"
|
| #include "ash/mus/screenlock_layout.h"
|
| #include "ash/mus/shelf_layout_manager.h"
|
| -#include "ash/mus/status_layout_manager.h"
|
| #include "ash/mus/window_manager.h"
|
| #include "base/bind.h"
|
| #include "base/command_line.h"
|
| @@ -65,6 +66,7 @@ RootWindowController::RootWindowController(WindowManager* window_manager,
|
| root_window_controller_common_->CreateContainers();
|
| root_window_controller_common_->CreateLayoutManagers();
|
| CreateLayoutManagers();
|
| + CreateStatusArea();
|
|
|
| disconnected_app_handler_.reset(new DisconnectedAppHandler(root));
|
|
|
| @@ -192,12 +194,7 @@ void RootWindowController::CreateLayoutManagers() {
|
| new ShelfLayoutManager(shelf_container->mus_window(), this);
|
| layout_managers_[shelf_container->mus_window()].reset(shelf_layout_manager);
|
|
|
| - wm_shelf_.reset(new WmShelfMus(shelf_layout_manager));
|
| -
|
| - WmWindowMus* status_container =
|
| - GetWindowByShellWindowId(kShellWindowId_StatusContainer);
|
| - layout_managers_[status_container->mus_window()].reset(
|
| - new StatusLayoutManager(status_container->mus_window()));
|
| + wm_shelf_.reset(new WmShelfMus(wm_root_window_controller_.get()));
|
|
|
| WmWindowMus* default_container =
|
| GetWindowByShellWindowId(kShellWindowId_DefaultContainer);
|
| @@ -218,5 +215,19 @@ void RootWindowController::CreateLayoutManagers() {
|
| base::WrapUnique(new PanelLayoutManager(panel_container)));
|
| }
|
|
|
| +void RootWindowController::CreateStatusArea() {
|
| + WmWindowMus* status_container =
|
| + GetWindowByShellWindowId(kShellWindowId_StatusContainer);
|
| + // Owned by native widget.
|
| + StatusAreaWidget* status_area_widget =
|
| + new StatusAreaWidget(status_container, wm_shelf_.get());
|
| + status_area_widget->CreateTrayViews();
|
| + // TODO(jamescook): Remove this when ash::StatusAreaLayoutManager and
|
| + // ash::ShelfLayoutManager are working in mash. http://crbug.com/621112
|
| + status_area_widget->SetBounds(gfx::Rect(845, 720, 120, 40));
|
| + if (WmShell::Get()->GetSessionStateDelegate()->IsActiveUserSessionStarted())
|
| + status_area_widget->Show();
|
| +}
|
| +
|
| } // namespace mus
|
| } // namespace ash
|
|
|