Chromium Code Reviews| Index: chrome/browser/notifications/notification_platform_bridge_mac.mm |
| diff --git a/chrome/browser/notifications/notification_platform_bridge_mac.mm b/chrome/browser/notifications/notification_platform_bridge_mac.mm |
| index e96756be9d07f2003944297157bc9d80f3a2cb7c..de66a065d20416e73f08a8443be41cab890888ec 100644 |
| --- a/chrome/browser/notifications/notification_platform_bridge_mac.mm |
| +++ b/chrome/browser/notifications/notification_platform_bridge_mac.mm |
| @@ -92,9 +92,18 @@ NotificationPlatformBridge* NotificationPlatformBridge::Create() { |
| NotificationPlatformBridgeMac::NotificationPlatformBridgeMac( |
| NSUserNotificationCenter* notification_center) |
| + : NotificationPlatformBridgeMac(notification_center, |
| + true /* set_delegate */) {} |
|
Nico
2016/07/12 17:54:38
please use /*set_delegate=*/true (the spelling you
Miguel Garcia
2016/07/13 14:05:16
Done.
|
| + |
| +NotificationPlatformBridgeMac::NotificationPlatformBridgeMac( |
| + NSUserNotificationCenter* notification_center, |
| + bool set_delegate) |
| : delegate_([NotificationCenterDelegate alloc]), |
| notification_center_(notification_center) { |
| - [notification_center_ setDelegate:delegate_.get()]; |
| + // OCMock does not support dynamic properties yet. |
| + // TODO(miguelg): remove once cbug.com/622753 is resolved. |
| + if (set_delegate) |
| + [notification_center_ setDelegate:delegate_.get()]; |
| } |
| NotificationPlatformBridgeMac::~NotificationPlatformBridgeMac() { |