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

Unified Diff: content/shell/browser/layout_test/layout_test_notification_manager.h

Issue 794633002: Remove ShowDesktopNotificationHostMsgParams in favor of PlatformNotificationData. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: comments Created 6 years 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: content/shell/browser/layout_test/layout_test_notification_manager.h
diff --git a/content/shell/browser/layout_test/layout_test_notification_manager.h b/content/shell/browser/layout_test/layout_test_notification_manager.h
index db6525a0819401209fca545f379e90ce1189cde5..229667fc54d95c65d8113ffc809a29d3b1b1a507 100644
--- a/content/shell/browser/layout_test/layout_test_notification_manager.h
+++ b/content/shell/browser/layout_test/layout_test_notification_manager.h
@@ -11,13 +11,14 @@
#include "base/callback.h"
#include "base/memory/weak_ptr.h"
#include "content/public/browser/platform_notification_service.h"
-#include "content/public/common/show_desktop_notification_params.h"
+#include "content/public/common/platform_notification_data.h"
#include "third_party/WebKit/public/platform/WebNotificationPermission.h"
#include "url/gurl.h"
namespace content {
class DesktopNotificationDelegate;
+struct PlatformNotificationData;
// Responsible for tracking active notifications and allowed origins for the
// Web Notification API when running layout tests.
@@ -49,14 +50,18 @@ class LayoutTestNotificationManager : public PlatformNotificationService {
const GURL& origin,
int render_process_id) override;
void DisplayNotification(BrowserContext* browser_context,
- const ShowDesktopNotificationHostMsgParams& params,
+ const GURL& origin,
+ const SkBitmap& icon,
+ const PlatformNotificationData& notification_data,
scoped_ptr<DesktopNotificationDelegate> delegate,
int render_process_id,
base::Closure* cancel_callback) override;
void DisplayPersistentNotification(
BrowserContext* browser_context,
int64 service_worker_registration_id,
- const ShowDesktopNotificationHostMsgParams& params,
+ const GURL& origin,
+ const SkBitmap& icon,
+ const PlatformNotificationData& notification_data,
int render_process_id) override;
void ClosePersistentNotification(
BrowserContext* browser_context,
@@ -70,15 +75,16 @@ class LayoutTestNotificationManager : public PlatformNotificationService {
// and a previous notification has been displayed using the same tag. All
// notifications, both page and persistent ones, will be considered for this.
void ReplaceNotificationIfNeeded(
- const ShowDesktopNotificationHostMsgParams& params);
+ const PlatformNotificationData& notification_data);
// Structure to represent the information of a persistent notification.
struct PersistentNotification {
PersistentNotification();
BrowserContext* browser_context;
+ GURL origin;
int64 service_worker_registration_id;
- ShowDesktopNotificationHostMsgParams notification_data;
+ PlatformNotificationData notification_data;
std::string persistent_id;
};

Powered by Google App Engine
This is Rietveld 408576698