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

Unified Diff: chrome/browser/notifications/notification_platform_bridge_mac.h

Issue 2158463003: Initial client side implementation of the XPC service (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: review comments Created 4 years, 3 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/notifications/notification_platform_bridge_mac.h
diff --git a/chrome/browser/notifications/notification_platform_bridge_mac.h b/chrome/browser/notifications/notification_platform_bridge_mac.h
index b48f1896242ed15cd148a6a7da6496afe8c9acb1..e584dd2a7ccae1828f0e8628f942d92a8a8c9bbd 100644
--- a/chrome/browser/notifications/notification_platform_bridge_mac.h
+++ b/chrome/browser/notifications/notification_platform_bridge_mac.h
@@ -16,8 +16,10 @@
class Notification;
@class NotificationCenterDelegate;
+@class NotificationRemoteDispatcher;
@class NSDictionary;
@class NSUserNotificationCenter;
+@class NSXPCConnection;
class PrefService;
// This class is an implementation of NotificationPlatformBridge that will
@@ -41,6 +43,10 @@ class NotificationPlatformBridgeMac : public NotificationPlatformBridge {
std::set<std::string>* notifications) const override;
bool SupportsNotificationCenter() const override;
+ // Processes a notification response generated from a user action
+ // (click close, etc.).
+ static void ProcessNotificationResponse(NSDictionary* response);
+
// Validates contents of the |response| dictionary as received from the system
// when a notification gets activated.
static bool VerifyNotificationData(NSDictionary* response) WARN_UNUSED_RESULT;
@@ -49,9 +55,14 @@ class NotificationPlatformBridgeMac : public NotificationPlatformBridge {
// Cocoa class that receives callbacks from the NSUserNotificationCenter.
base::scoped_nsobject<NotificationCenterDelegate> delegate_;
- // The notification center to use, this can be overriden in tests
+ // The notification center to use for local banner notifications,
+ // this can be overriden in tests.
NSUserNotificationCenter* notification_center_;
+ // The object in charge of dispatching remote notifications.
+ base::scoped_nsobject<NotificationRemoteDispatcher>
+ notification_remote_dispatcher_;
+
DISALLOW_COPY_AND_ASSIGN(NotificationPlatformBridgeMac);
};

Powered by Google App Engine
This is Rietveld 408576698