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

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

Issue 2935333003: Propagate the user gesture bit when requesting push messaging permission. (Closed)
Patch Set: ThreadSafe user gesture check Created 3 years, 6 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_PUSH_MESSAGING_SERVICE_H_ 5 #ifndef CONTENT_PUBLIC_BROWSER_PUSH_MESSAGING_SERVICE_H_
6 #define CONTENT_PUBLIC_BROWSER_PUSH_MESSAGING_SERVICE_H_ 6 #define CONTENT_PUBLIC_BROWSER_PUSH_MESSAGING_SERVICE_H_
7 7
8 #include <stdint.h> 8 #include <stdint.h>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
46 virtual GURL GetEndpoint(bool standard_protocol) const = 0; 46 virtual GURL GetEndpoint(bool standard_protocol) const = 0;
47 47
48 // Subscribe the given |options.sender_info| with the push messaging service 48 // Subscribe the given |options.sender_info| with the push messaging service
49 // in a document context. The frame is known and a permission UI may be 49 // in a document context. The frame is known and a permission UI may be
50 // displayed to the user. 50 // displayed to the user.
51 virtual void SubscribeFromDocument(const GURL& requesting_origin, 51 virtual void SubscribeFromDocument(const GURL& requesting_origin,
52 int64_t service_worker_registration_id, 52 int64_t service_worker_registration_id,
53 int renderer_id, 53 int renderer_id,
54 int render_frame_id, 54 int render_frame_id,
55 const PushSubscriptionOptions& options, 55 const PushSubscriptionOptions& options,
56 bool user_gesture,
56 const RegisterCallback& callback) = 0; 57 const RegisterCallback& callback) = 0;
57 58
58 // Subscribe the given |options.sender_info| with the push messaging service. 59 // Subscribe the given |options.sender_info| with the push messaging service.
59 // The frame is not known so if permission was not previously granted by the 60 // The frame is not known so if permission was not previously granted by the
60 // user this request should fail. 61 // user this request should fail.
61 virtual void SubscribeFromWorker(const GURL& requesting_origin, 62 virtual void SubscribeFromWorker(const GURL& requesting_origin,
62 int64_t service_worker_registration_id, 63 int64_t service_worker_registration_id,
63 const PushSubscriptionOptions& options, 64 const PushSubscriptionOptions& options,
64 const RegisterCallback& callback) = 0; 65 const RegisterCallback& callback) = 0;
65 66
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
123 const GURL& origin, 124 const GURL& origin,
124 int64_t service_worker_registration_id, 125 int64_t service_worker_registration_id,
125 const std::string& subscription_id, 126 const std::string& subscription_id,
126 const std::string& sender_id, 127 const std::string& sender_id,
127 const base::Closure& callback); 128 const base::Closure& callback);
128 }; 129 };
129 130
130 } // namespace content 131 } // namespace content
131 132
132 #endif // CONTENT_PUBLIC_BROWSER_PUSH_MESSAGING_SERVICE_H_ 133 #endif // CONTENT_PUBLIC_BROWSER_PUSH_MESSAGING_SERVICE_H_
OLDNEW
« no previous file with comments | « content/common/push_messaging.mojom ('k') | content/renderer/push_messaging/push_messaging_client.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698