| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "chrome/browser/ui/views/message_center/web_notification_tray.h" | 5 #include "chrome/browser/ui/views/message_center/web_notification_tray.h" |
| 6 | 6 |
| 7 #include "chrome/browser/browser_process.h" | 7 #include "chrome/browser/browser_process.h" |
| 8 #include "ui/gfx/screen.h" | 8 #include "ui/gfx/screen.h" |
| 9 #include "ui/message_center/message_center_tray.h" | 9 #include "ui/message_center/message_center_tray.h" |
| 10 #include "ui/message_center/message_center_tray_delegate.h" | 10 #include "ui/message_center/message_center_tray_delegate.h" |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 // problems. | 31 // problems. |
| 32 popup_collection_.reset(); | 32 popup_collection_.reset(); |
| 33 message_center_tray_.reset(); | 33 message_center_tray_.reset(); |
| 34 } | 34 } |
| 35 | 35 |
| 36 message_center::MessageCenter* WebNotificationTray::message_center() { | 36 message_center::MessageCenter* WebNotificationTray::message_center() { |
| 37 return message_center_tray_->message_center(); | 37 return message_center_tray_->message_center(); |
| 38 } | 38 } |
| 39 | 39 |
| 40 bool WebNotificationTray::ShowPopups() { | 40 bool WebNotificationTray::ShowPopups() { |
| 41 alignment_delegate_->StartObserving(gfx::Screen::GetNativeScreen()); | 41 alignment_delegate_->StartObserving(gfx::Screen::GetScreen()); |
| 42 popup_collection_->DoUpdateIfPossible(); | 42 popup_collection_->DoUpdateIfPossible(); |
| 43 return true; | 43 return true; |
| 44 } | 44 } |
| 45 | 45 |
| 46 void WebNotificationTray::HidePopups() { | 46 void WebNotificationTray::HidePopups() { |
| 47 DCHECK(popup_collection_.get()); | 47 DCHECK(popup_collection_.get()); |
| 48 popup_collection_->MarkAllPopupsShown(); | 48 popup_collection_->MarkAllPopupsShown(); |
| 49 } | 49 } |
| 50 | 50 |
| 51 bool WebNotificationTray::ShowMessageCenter() { | 51 bool WebNotificationTray::ShowMessageCenter() { |
| (...skipping 16 matching lines...) Expand all Loading... |
| 68 } | 68 } |
| 69 | 69 |
| 70 void WebNotificationTray::OnMessageCenterTrayChanged() { | 70 void WebNotificationTray::OnMessageCenterTrayChanged() { |
| 71 } | 71 } |
| 72 | 72 |
| 73 MessageCenterTray* WebNotificationTray::GetMessageCenterTray() { | 73 MessageCenterTray* WebNotificationTray::GetMessageCenterTray() { |
| 74 return message_center_tray_.get(); | 74 return message_center_tray_.get(); |
| 75 } | 75 } |
| 76 | 76 |
| 77 } // namespace message_center | 77 } // namespace message_center |
| OLD | NEW |