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

Unified Diff: third_party/WebKit/public/platform/modules/notifications/WebNotificationManager.h

Issue 1904163002: Move Web Notifications to use Mojo Base URL: https://chromium.googlesource.com/chromium/src.git@skbitmap-blink
Patch Set: it works \o/ Created 4 years, 8 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: third_party/WebKit/public/platform/modules/notifications/WebNotificationManager.h
diff --git a/third_party/WebKit/public/platform/modules/notifications/WebNotificationManager.h b/third_party/WebKit/public/platform/modules/notifications/WebNotificationManager.h
deleted file mode 100644
index 1e6ced998917d81643b2eb59103767b23398ac53..0000000000000000000000000000000000000000
--- a/third_party/WebKit/public/platform/modules/notifications/WebNotificationManager.h
+++ /dev/null
@@ -1,70 +0,0 @@
-// Copyright 2014 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#ifndef WebNotificationManager_h
-#define WebNotificationManager_h
-
-#include "public/platform/WebCallbacks.h"
-#include "public/platform/WebString.h"
-#include "public/platform/WebVector.h"
-#include "public/platform/modules/notifications/WebNotificationData.h"
-#include "public/platform/modules/notifications/WebNotificationResources.h"
-#include <memory>
-#include <stdint.h>
-
-namespace blink {
-
-namespace mojom {
-enum class PermissionStatus;
-}
-
-class WebNotificationDelegate;
-class WebSecurityOrigin;
-class WebServiceWorkerRegistration;
-
-// Structure representing the info associated with a persistent notification.
-struct WebPersistentNotificationInfo {
- int64_t persistentId = 0;
- WebNotificationData data;
-};
-
-using WebNotificationGetCallbacks = WebCallbacks<const WebVector<WebPersistentNotificationInfo>&, void>;
-using WebNotificationShowCallbacks = WebCallbacks<void, void>;
-
-// Provides the services to show platform notifications to the user.
-class WebNotificationManager {
-public:
- virtual ~WebNotificationManager() { }
-
- // Shows a page notification on the user's system. These notifications will have their
- // events delivered to the delegate specified in this call.
- virtual void show(const WebSecurityOrigin&, const WebNotificationData&, std::unique_ptr<WebNotificationResources>, WebNotificationDelegate*) = 0;
-
- // Shows a persistent notification on the user's system. These notifications will have
- // their events delivered to a Service Worker rather than the object's delegate. Will
- // take ownership of the WebNotificationShowCallbacks object.
- virtual void showPersistent(const WebSecurityOrigin&, const WebNotificationData&, std::unique_ptr<WebNotificationResources>, WebServiceWorkerRegistration*, WebNotificationShowCallbacks*) = 0;
-
- // Asynchronously gets the persistent notifications belonging to the Service Worker Registration.
- // If |filterTag| is not an empty string, only the notification with the given tag will be
- // considered. Will take ownership of the WebNotificationGetCallbacks object.
- virtual void getNotifications(const WebString& filterTag, WebServiceWorkerRegistration*, WebNotificationGetCallbacks*) = 0;
-
- // Closes a notification previously shown, and removes it if being shown.
- virtual void close(WebNotificationDelegate*) = 0;
-
- // Closes a persistent notification identified by its persistent notification Id.
- virtual void closePersistent(const WebSecurityOrigin&, int64_t persistentNotificationId) = 0;
-
- // Indicates that the delegate object is being destroyed, and must no longer
- // be used by the embedder to dispatch events.
- virtual void notifyDelegateDestroyed(WebNotificationDelegate*) = 0;
-
- // Synchronously checks the permission level for the given origin.
- virtual mojom::PermissionStatus checkPermission(const WebSecurityOrigin&) = 0;
-};
-
-} // namespace blink
-
-#endif // WebNotificationManager_h

Powered by Google App Engine
This is Rietveld 408576698