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/root_window_controller.h" | 7 #include "ash/root_window_controller.h" |
8 #include "ash/shelf/shelf_layout_manager.h" | 8 #include "ash/shelf/shelf_layout_manager.h" |
9 #include "ash/shelf/shelf_widget.h" | 9 #include "ash/shelf/shelf_widget.h" |
10 #include "ash/shell.h" | 10 #include "ash/shell.h" |
(...skipping 99 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
110 (web_notification_tray_ && | 110 (web_notification_tray_ && |
111 web_notification_tray_->IsMouseInNotificationBubble()); | 111 web_notification_tray_->IsMouseInNotificationBubble()); |
112 } | 112 } |
113 | 113 |
114 bool StatusAreaWidget::IsMessageBubbleShown() const { | 114 bool StatusAreaWidget::IsMessageBubbleShown() const { |
115 return ((system_tray_ && system_tray_->IsAnyBubbleVisible()) || | 115 return ((system_tray_ && system_tray_->IsAnyBubbleVisible()) || |
116 (web_notification_tray_ && | 116 (web_notification_tray_ && |
117 web_notification_tray_->IsMessageCenterBubbleVisible())); | 117 web_notification_tray_->IsMessageCenterBubbleVisible())); |
118 } | 118 } |
119 | 119 |
| 120 void StatusAreaWidget::ShelfDimChanged() { |
| 121 web_notification_tray_->SchedulePaint(); |
| 122 system_tray_->SchedulePaint(); |
| 123 #if defined(OS_CHROMEOS) |
| 124 virtual_keyboard_tray_->SchedulePaint(); |
| 125 logout_button_tray_->SchedulePaint(); |
| 126 #endif |
| 127 overview_button_tray_->SchedulePaint(); |
| 128 } |
| 129 |
120 void StatusAreaWidget::OnNativeWidgetActivationChanged(bool active) { | 130 void StatusAreaWidget::OnNativeWidgetActivationChanged(bool active) { |
121 Widget::OnNativeWidgetActivationChanged(active); | 131 Widget::OnNativeWidgetActivationChanged(active); |
122 if (active) | 132 if (active) |
123 status_area_widget_delegate_->SetPaneFocusAndFocusDefault(); | 133 status_area_widget_delegate_->SetPaneFocusAndFocusDefault(); |
124 } | 134 } |
125 | 135 |
126 void StatusAreaWidget::AddSystemTray() { | 136 void StatusAreaWidget::AddSystemTray() { |
127 system_tray_ = new SystemTray(this); | 137 system_tray_ = new SystemTray(this); |
128 status_area_widget_delegate_->AddTray(system_tray_); | 138 status_area_widget_delegate_->AddTray(system_tray_); |
129 } | 139 } |
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
183 web_notification_tray_->UpdateAfterLoginStatusChange(login_status); | 193 web_notification_tray_->UpdateAfterLoginStatusChange(login_status); |
184 #if defined(OS_CHROMEOS) | 194 #if defined(OS_CHROMEOS) |
185 if (logout_button_tray_) | 195 if (logout_button_tray_) |
186 logout_button_tray_->UpdateAfterLoginStatusChange(login_status); | 196 logout_button_tray_->UpdateAfterLoginStatusChange(login_status); |
187 #endif | 197 #endif |
188 if (overview_button_tray_) | 198 if (overview_button_tray_) |
189 overview_button_tray_->UpdateAfterLoginStatusChange(login_status); | 199 overview_button_tray_->UpdateAfterLoginStatusChange(login_status); |
190 } | 200 } |
191 | 201 |
192 } // namespace ash | 202 } // namespace ash |
OLD | NEW |