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

Unified Diff: public/platform/WebNavigatorConnectProvider.h

Issue 799703003: Expose the origin of the client calling navigator.connect. (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: 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
« no previous file with comments | « Source/modules/navigatorconnect/NavigatorConnect.cpp ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: public/platform/WebNavigatorConnectProvider.h
diff --git a/public/platform/WebNavigatorConnectProvider.h b/public/platform/WebNavigatorConnectProvider.h
index 1b77b0ebc10efa7d174d4eb7f4ff14a9737d373d..f4e9f0d2eaa70eaf7f5ef07e39024bf8922ddd30 100644
--- a/public/platform/WebNavigatorConnectProvider.h
+++ b/public/platform/WebNavigatorConnectProvider.h
@@ -10,16 +10,19 @@
namespace blink {
class WebMessagePortChannel;
+class WebString;
class WebURL;
class WebNavigatorConnectProvider {
public:
virtual ~WebNavigatorConnectProvider() { }
- // Initiates a connection to the given URL. When succesfull the service
- // can communicate with the client over the given channel.
+ // Initiates a connection from the given origin to the given URL. When
+ // successful the service can communicate with the client over the given
+ // channel. The origin isn't passed as WebSecurityOrigin because that would
+ // be a layering violation (platform/ code shouldn't depend on web/ code).
// Ownership of the WebMessagePortChannel and WebCallbacks is transferred to the provider.
- virtual void connect(const WebURL&, WebMessagePortChannel*, WebCallbacks<void, void>*) { }
+ virtual void connect(const WebURL&, const WebString& origin, WebMessagePortChannel*, WebCallbacks<void, void>*) { }
};
} // namespace blink
« no previous file with comments | « Source/modules/navigatorconnect/NavigatorConnect.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698