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

Side by Side Diff: chrome/browser/ui/cocoa/notifications/notification_response_builder_mac.mm

Issue 2095223002: Refactor notification operation functionality out of PNS (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: remove renamed files Created 4 years, 5 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 #import "chrome/browser/ui/cocoa/notifications/notification_response_builder_mac .h" 5 #import "chrome/browser/ui/cocoa/notifications/notification_response_builder_mac .h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "chrome/browser/ui/cocoa/notifications/notification_constants_mac.h" 8 #include "chrome/browser/ui/cocoa/notifications/notification_constants_mac.h"
9 9
10 namespace { 10 namespace {
11 11
12 // Make sure this Obj-C enum is kept in sync with the 12 // Make sure this Obj-C enum is kept in sync with the
13 // PlatformNotificationServiceImpl NotificationOperation enum. 13 // NotificationCommon::Operation enum.
14 // The latter cannot be reused because the XPC service is not aware of 14 // The latter cannot be reused because the XPC service is not aware of
15 // PlatformNotificationCenter. 15 // PlatformNotificationCenter.
16 enum NotificationOperation { 16 enum NotificationOperation {
17 NOTIFICATION_CLICK = 0, 17 NOTIFICATION_CLICK = 0,
18 NOTIFICATION_CLOSE = 1, 18 NOTIFICATION_CLOSE = 1,
19 NOTIFICATION_SETTINGS = 2 19 NOTIFICATION_SETTINGS = 2
20 }; 20 };
21 } // namespace 21 } // namespace
22 22
23 @implementation NotificationResponseBuilder 23 @implementation NotificationResponseBuilder
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
89 notification_constants::kNotificationProfileId : profileId, 89 notification_constants::kNotificationProfileId : profileId,
90 notification_constants::kNotificationIncognito : incognito, 90 notification_constants::kNotificationIncognito : incognito,
91 notification_constants::kNotificationOperation : 91 notification_constants::kNotificationOperation :
92 [NSNumber numberWithInt:operation], 92 [NSNumber numberWithInt:operation],
93 notification_constants:: 93 notification_constants::
94 kNotificationButtonIndex : [NSNumber numberWithInt:buttonIndex], 94 kNotificationButtonIndex : [NSNumber numberWithInt:buttonIndex],
95 }; 95 };
96 } 96 }
97 97
98 @end 98 @end
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698