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

Side by Side Diff: ui/arc/notification/arc_notification_manager.h

Issue 1603753003: Support buttons on ARC Notifications (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 11 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
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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_ARC_NOTIFICATION_ARC_NOTIFICATION_MANAGER_H_ 5 #ifndef UI_ARC_NOTIFICATION_ARC_NOTIFICATION_MANAGER_H_
6 #define UI_ARC_NOTIFICATION_ARC_NOTIFICATION_MANAGER_H_ 6 #define UI_ARC_NOTIFICATION_ARC_NOTIFICATION_MANAGER_H_
7 7
8 #include <map> 8 #include <map>
9 #include <string> 9 #include <string>
10 10
(...skipping 17 matching lines...) Expand all
28 // ArcBridgeService::Observer implementation: 28 // ArcBridgeService::Observer implementation:
29 void OnNotificationsInstanceReady() override; 29 void OnNotificationsInstanceReady() override;
30 30
31 // NotificationsHost implementation: 31 // NotificationsHost implementation:
32 void OnNotificationPosted(ArcNotificationDataPtr data) override; 32 void OnNotificationPosted(ArcNotificationDataPtr data) override;
33 void OnNotificationRemoved(const mojo::String& key) override; 33 void OnNotificationRemoved(const mojo::String& key) override;
34 34
35 // Methods called from ArcNotificationItem: 35 // Methods called from ArcNotificationItem:
36 void SendNotificationRemovedFromChrome(const std::string& key); 36 void SendNotificationRemovedFromChrome(const std::string& key);
37 void SendNotificationClickedOnChrome(const std::string& key); 37 void SendNotificationClickedOnChrome(const std::string& key);
38 void SendNotificationButtonClickedOnChrome(
39 const std::string& key, int button_index);
38 40
39 private: 41 private:
40 ArcBridgeService* const arc_bridge_; 42 ArcBridgeService* const arc_bridge_;
41 const AccountId main_profile_id_; 43 const AccountId main_profile_id_;
42 44
43 using ItemMap = 45 using ItemMap =
44 base::ScopedPtrHashMap<std::string, scoped_ptr<ArcNotificationItem>>; 46 base::ScopedPtrHashMap<std::string, scoped_ptr<ArcNotificationItem>>;
45 ItemMap items_; 47 ItemMap items_;
46 48
47 mojo::Binding<arc::NotificationsHost> binding_; 49 mojo::Binding<arc::NotificationsHost> binding_;
48 50
49 DISALLOW_COPY_AND_ASSIGN(ArcNotificationManager); 51 DISALLOW_COPY_AND_ASSIGN(ArcNotificationManager);
50 }; 52 };
51 53
52 } // namespace arc 54 } // namespace arc
53 55
54 #endif // UI_ARC_NOTIFICATION_ARC_NOTIFICATION_MANAGER_H_ 56 #endif // UI_ARC_NOTIFICATION_ARC_NOTIFICATION_MANAGER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698