| 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/system/status_area_widget.h" | 5 #include "ash/system/status_area_widget.h" |
| 6 | 6 |
| 7 #include "ash/material_design/material_design_controller.h" | 7 #include "ash/material_design/material_design_controller.h" |
| 8 #include "ash/public/cpp/shell_window_ids.h" | 8 #include "ash/public/cpp/shell_window_ids.h" |
| 9 #include "ash/root_window_controller.h" | 9 #include "ash/root_window_controller.h" |
| 10 #include "ash/shelf/wm_shelf.h" | 10 #include "ash/shelf/wm_shelf.h" |
| (...skipping 27 matching lines...) Expand all Loading... |
| 38 ime_menu_tray_(nullptr), | 38 ime_menu_tray_(nullptr), |
| 39 login_status_(LoginStatus::NOT_LOGGED_IN), | 39 login_status_(LoginStatus::NOT_LOGGED_IN), |
| 40 wm_shelf_(wm_shelf) { | 40 wm_shelf_(wm_shelf) { |
| 41 views::Widget::InitParams params( | 41 views::Widget::InitParams params( |
| 42 views::Widget::InitParams::TYPE_WINDOW_FRAMELESS); | 42 views::Widget::InitParams::TYPE_WINDOW_FRAMELESS); |
| 43 params.delegate = status_area_widget_delegate_; | 43 params.delegate = status_area_widget_delegate_; |
| 44 params.name = "StatusAreaWidget"; | 44 params.name = "StatusAreaWidget"; |
| 45 params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; | 45 params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; |
| 46 status_container->GetRootWindowController() | 46 status_container->GetRootWindowController() |
| 47 ->ConfigureWidgetInitParamsForContainer( | 47 ->ConfigureWidgetInitParamsForContainer( |
| 48 this, status_container->GetShellWindowId(), ¶ms); | 48 this, status_container->aura_window()->id(), ¶ms); |
| 49 Init(params); | 49 Init(params); |
| 50 set_focus_on_creation(false); | 50 set_focus_on_creation(false); |
| 51 SetContentsView(status_area_widget_delegate_); | 51 SetContentsView(status_area_widget_delegate_); |
| 52 } | 52 } |
| 53 | 53 |
| 54 StatusAreaWidget::~StatusAreaWidget() {} | 54 StatusAreaWidget::~StatusAreaWidget() {} |
| 55 | 55 |
| 56 void StatusAreaWidget::CreateTrayViews() { | 56 void StatusAreaWidget::CreateTrayViews() { |
| 57 AddOverviewButtonTray(); | 57 AddOverviewButtonTray(); |
| 58 AddSystemTray(); | 58 AddSystemTray(); |
| (...skipping 174 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 233 ime_menu_tray_ = new ImeMenuTray(wm_shelf_); | 233 ime_menu_tray_ = new ImeMenuTray(wm_shelf_); |
| 234 status_area_widget_delegate_->AddTray(ime_menu_tray_); | 234 status_area_widget_delegate_->AddTray(ime_menu_tray_); |
| 235 } | 235 } |
| 236 | 236 |
| 237 void StatusAreaWidget::AddOverviewButtonTray() { | 237 void StatusAreaWidget::AddOverviewButtonTray() { |
| 238 overview_button_tray_ = new OverviewButtonTray(wm_shelf_); | 238 overview_button_tray_ = new OverviewButtonTray(wm_shelf_); |
| 239 status_area_widget_delegate_->AddTray(overview_button_tray_); | 239 status_area_widget_delegate_->AddTray(overview_button_tray_); |
| 240 } | 240 } |
| 241 | 241 |
| 242 } // namespace ash | 242 } // namespace ash |
| OLD | NEW |