| 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/web_notification/web_notification_tray.h" | 5 #include "ash/system/web_notification/web_notification_tray.h" |
| 6 | 6 |
| 7 #include "ash/ash_switches.h" | 7 #include "ash/ash_switches.h" |
| 8 #include "ash/root_window_controller.h" | 8 #include "ash/root_window_controller.h" |
| 9 #include "ash/shelf/shelf_layout_manager.h" | 9 #include "ash/shelf/shelf_layout_manager.h" |
| 10 #include "ash/shelf/shelf_layout_manager_observer.h" | 10 #include "ash/shelf/shelf_layout_manager_observer.h" |
| (...skipping 268 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 279 show_message_center_on_unlock_ = false; | 279 show_message_center_on_unlock_ = false; |
| 280 status_area_widget()->SetHideSystemNotifications(false); | 280 status_area_widget()->SetHideSystemNotifications(false); |
| 281 GetShelfLayoutManager()->UpdateAutoHideState(); | 281 GetShelfLayoutManager()->UpdateAutoHideState(); |
| 282 button_->SetBubbleVisible(false); | 282 button_->SetBubbleVisible(false); |
| 283 } | 283 } |
| 284 | 284 |
| 285 void WebNotificationTray::SetSystemTrayHeight(int height) { | 285 void WebNotificationTray::SetSystemTrayHeight(int height) { |
| 286 popup_alignment_delegate_->SetSystemTrayHeight(height); | 286 popup_alignment_delegate_->SetSystemTrayHeight(height); |
| 287 } | 287 } |
| 288 | 288 |
| 289 int WebNotificationTray::system_tray_height() const { |
| 290 return popup_alignment_delegate_->system_tray_height(); |
| 291 } |
| 292 |
| 289 bool WebNotificationTray::ShowPopups() { | 293 bool WebNotificationTray::ShowPopups() { |
| 290 if (message_center_bubble()) | 294 if (message_center_bubble()) |
| 291 return false; | 295 return false; |
| 292 | 296 |
| 293 popup_collection_->DoUpdateIfPossible(); | 297 popup_collection_->DoUpdateIfPossible(); |
| 294 return true; | 298 return true; |
| 295 } | 299 } |
| 296 | 300 |
| 297 void WebNotificationTray::HidePopups() { | 301 void WebNotificationTray::HidePopups() { |
| 298 DCHECK(popup_collection_.get()); | 302 DCHECK(popup_collection_.get()); |
| (...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 504 | 508 |
| 505 message_center::MessageCenterBubble* | 509 message_center::MessageCenterBubble* |
| 506 WebNotificationTray::GetMessageCenterBubbleForTest() { | 510 WebNotificationTray::GetMessageCenterBubbleForTest() { |
| 507 if (!message_center_bubble()) | 511 if (!message_center_bubble()) |
| 508 return NULL; | 512 return NULL; |
| 509 return static_cast<message_center::MessageCenterBubble*>( | 513 return static_cast<message_center::MessageCenterBubble*>( |
| 510 message_center_bubble()->bubble()); | 514 message_center_bubble()->bubble()); |
| 511 } | 515 } |
| 512 | 516 |
| 513 } // namespace ash | 517 } // namespace ash |
| OLD | NEW |