Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(509)

Side by Side Diff: ui/message_center/message_center_impl.h

Issue 2025613002: Reland: Show message center on lock screen (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « ui/message_center/message_center.h ('k') | ui/message_center/message_center_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 #ifndef UI_MESSAGE_CENTER_MESSAGE_CENTER_IMPL_H_ 5 #ifndef UI_MESSAGE_CENTER_MESSAGE_CENTER_IMPL_H_
6 #define UI_MESSAGE_CENTER_MESSAGE_CENTER_IMPL_H_ 6 #define UI_MESSAGE_CENTER_MESSAGE_CENTER_IMPL_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <memory> 10 #include <memory>
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 void AddObserver(MessageCenterObserver* observer) override; 42 void AddObserver(MessageCenterObserver* observer) override;
43 void RemoveObserver(MessageCenterObserver* observer) override; 43 void RemoveObserver(MessageCenterObserver* observer) override;
44 void AddNotificationBlocker(NotificationBlocker* blocker) override; 44 void AddNotificationBlocker(NotificationBlocker* blocker) override;
45 void RemoveNotificationBlocker(NotificationBlocker* blocker) override; 45 void RemoveNotificationBlocker(NotificationBlocker* blocker) override;
46 void SetVisibility(Visibility visible) override; 46 void SetVisibility(Visibility visible) override;
47 bool IsMessageCenterVisible() const override; 47 bool IsMessageCenterVisible() const override;
48 size_t NotificationCount() const override; 48 size_t NotificationCount() const override;
49 size_t UnreadNotificationCount() const override; 49 size_t UnreadNotificationCount() const override;
50 bool HasPopupNotifications() const override; 50 bool HasPopupNotifications() const override;
51 bool IsQuietMode() const override; 51 bool IsQuietMode() const override;
52 bool IsLockedState() const override;
52 bool HasClickedListener(const std::string& id) override; 53 bool HasClickedListener(const std::string& id) override;
53 message_center::Notification* FindVisibleNotificationById( 54 message_center::Notification* FindVisibleNotificationById(
54 const std::string& id) override; 55 const std::string& id) override;
55 const NotificationList::Notifications& GetVisibleNotifications() override; 56 const NotificationList::Notifications& GetVisibleNotifications() override;
56 NotificationList::PopupNotifications GetPopupNotifications() override; 57 NotificationList::PopupNotifications GetPopupNotifications() override;
57 void AddNotification(std::unique_ptr<Notification> notification) override; 58 void AddNotification(std::unique_ptr<Notification> notification) override;
58 void UpdateNotification( 59 void UpdateNotification(
59 const std::string& old_id, 60 const std::string& old_id,
60 std::unique_ptr<Notification> new_notification) override; 61 std::unique_ptr<Notification> new_notification) override;
61 void RemoveNotification(const std::string& id, bool by_user) override; 62 void RemoveNotification(const std::string& id, bool by_user) override;
(...skipping 10 matching lines...) Expand all
72 void ClickOnNotificationButton(const std::string& id, 73 void ClickOnNotificationButton(const std::string& id,
73 int button_index) override; 74 int button_index) override;
74 void ClickOnSettingsButton(const std::string& id) override; 75 void ClickOnSettingsButton(const std::string& id) override;
75 void MarkSinglePopupAsShown(const std::string& id, 76 void MarkSinglePopupAsShown(const std::string& id,
76 bool mark_notification_as_read) override; 77 bool mark_notification_as_read) override;
77 void DisplayedNotification(const std::string& id, 78 void DisplayedNotification(const std::string& id,
78 const DisplaySource source) override; 79 const DisplaySource source) override;
79 void SetNotifierSettingsProvider(NotifierSettingsProvider* provider) override; 80 void SetNotifierSettingsProvider(NotifierSettingsProvider* provider) override;
80 NotifierSettingsProvider* GetNotifierSettingsProvider() override; 81 NotifierSettingsProvider* GetNotifierSettingsProvider() override;
81 void SetQuietMode(bool in_quiet_mode) override; 82 void SetQuietMode(bool in_quiet_mode) override;
83 void SetLockedState(bool locked) override;
82 void EnterQuietModeWithExpire(const base::TimeDelta& expires_in) override; 84 void EnterQuietModeWithExpire(const base::TimeDelta& expires_in) override;
83 void RestartPopupTimers() override; 85 void RestartPopupTimers() override;
84 void PausePopupTimers() override; 86 void PausePopupTimers() override;
85 void ForceNotificationFlush(const std::string& id) override; 87 void ForceNotificationFlush(const std::string& id) override;
86 88
87 // NotificationBlocker::Observer overrides: 89 // NotificationBlocker::Observer overrides:
88 void OnBlockingStateChanged(NotificationBlocker* blocker) override; 90 void OnBlockingStateChanged(NotificationBlocker* blocker) override;
89 91
90 // message_center::NotifierSettingsObserver overrides: 92 // message_center::NotifierSettingsObserver overrides:
91 void UpdateIconImage(const NotifierId& notifier_id, 93 void UpdateIconImage(const NotifierId& notifier_id,
(...skipping 27 matching lines...) Expand all
119 void RemoveNotificationsForNotifierId(const NotifierId& notifier_id); 121 void RemoveNotificationsForNotifierId(const NotifierId& notifier_id);
120 122
121 std::unique_ptr<NotificationList> notification_list_; 123 std::unique_ptr<NotificationList> notification_list_;
122 NotificationCache notification_cache_; 124 NotificationCache notification_cache_;
123 base::ObserverList<MessageCenterObserver> observer_list_; 125 base::ObserverList<MessageCenterObserver> observer_list_;
124 std::unique_ptr<PopupTimersController> popup_timers_controller_; 126 std::unique_ptr<PopupTimersController> popup_timers_controller_;
125 std::unique_ptr<base::OneShotTimer> quiet_mode_timer_; 127 std::unique_ptr<base::OneShotTimer> quiet_mode_timer_;
126 NotifierSettingsProvider* settings_provider_; 128 NotifierSettingsProvider* settings_provider_;
127 std::vector<NotificationBlocker*> blockers_; 129 std::vector<NotificationBlocker*> blockers_;
128 130
131 bool locked_ = false;
132 bool visible_ = false;
133
129 // Queue for the notifications to delay the addition/updates when the message 134 // Queue for the notifications to delay the addition/updates when the message
130 // center is visible. 135 // center is visible.
131 std::unique_ptr<internal::ChangeQueue> notification_queue_; 136 std::unique_ptr<internal::ChangeQueue> notification_queue_;
132 137
133 DISALLOW_COPY_AND_ASSIGN(MessageCenterImpl); 138 DISALLOW_COPY_AND_ASSIGN(MessageCenterImpl);
134 }; 139 };
135 140
136 } // namespace message_center 141 } // namespace message_center
137 142
138 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_H_ 143 #endif // UI_MESSAGE_CENTER_MESSAGE_CENTER_H_
OLDNEW
« no previous file with comments | « ui/message_center/message_center.h ('k') | ui/message_center/message_center_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698