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

Side by Side Diff: content/public/browser/platform_notification_service.h

Issue 1127013008: Beginnings of synchronizing notifications in the notification database. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 7 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 CONTENT_PUBLIC_BROWSER_PLATFORM_NOTIFICATION_SERVICE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_PLATFORM_NOTIFICATION_SERVICE_H_
6 #define CONTENT_PUBLIC_BROWSER_PLATFORM_NOTIFICATION_SERVICE_H_ 6 #define CONTENT_PUBLIC_BROWSER_PLATFORM_NOTIFICATION_SERVICE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <set>
9 #include <string> 10 #include <string>
10 11
11 #include "base/callback_forward.h" 12 #include "base/callback_forward.h"
12 #include "base/memory/scoped_ptr.h" 13 #include "base/memory/scoped_ptr.h"
13 #include "content/common/content_export.h" 14 #include "content/common/content_export.h"
14 #include "third_party/WebKit/public/platform/modules/notifications/WebNotificati onPermission.h" 15 #include "third_party/WebKit/public/platform/modules/notifications/WebNotificati onPermission.h"
15 16
16 class GURL; 17 class GURL;
17 class SkBitmap; 18 class SkBitmap;
18 19
(...skipping 46 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 int64_t persistent_notification_id, 66 int64_t persistent_notification_id,
66 const GURL& origin, 67 const GURL& origin,
67 const SkBitmap& icon, 68 const SkBitmap& icon,
68 const PlatformNotificationData& notification_data) = 0; 69 const PlatformNotificationData& notification_data) = 0;
69 70
70 // Closes the persistent notification identified by 71 // Closes the persistent notification identified by
71 // |persistent_notification_id|. This method must be called on the UI thread. 72 // |persistent_notification_id|. This method must be called on the UI thread.
72 virtual void ClosePersistentNotification( 73 virtual void ClosePersistentNotification(
73 BrowserContext* browser_context, 74 BrowserContext* browser_context,
74 int64_t persistent_notification_id) = 0; 75 int64_t persistent_notification_id) = 0;
76
77 // Writesthe ids of all currently displaying persistent notifications for the
johnme 2015/05/14 15:22:32 Writesthe
Peter Beverloo 2015/05/14 16:03:35 Oops. Done.
78 // given |browser_context| to |displayed_notifications|. Returns whether the
79 // platform is able to provide for such a set.
johnme 2015/05/14 15:22:32 no for
Peter Beverloo 2015/05/14 16:03:35 Done.
80 virtual bool GetDisplayedPersistentNotifications(
81 BrowserContext* browser_context,
82 std::set<std::string>* displayed_notifications) = 0;
johnme 2015/05/14 15:22:32 Surely this should be std::set<int64_t>? Or is thi
Peter Beverloo 2015/05/14 16:03:35 These should be strings, as is visible in my API p
75 }; 83 };
76 84
77 } // namespace content 85 } // namespace content
78 86
79 #endif // CONTENT_PUBLIC_BROWSER_PLATFORM_NOTIFICATION_SERVICE_H_ 87 #endif // CONTENT_PUBLIC_BROWSER_PLATFORM_NOTIFICATION_SERVICE_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698