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

Unified Diff: content/public/common/navigator_connect_client.h

Issue 861373002: Refactor navigator.connect code to make it more flexible. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix typo Created 5 years, 11 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: content/public/common/navigator_connect_client.h
diff --git a/content/common/navigator_connect_types.h b/content/public/common/navigator_connect_client.h
similarity index 30%
rename from content/common/navigator_connect_types.h
rename to content/public/common/navigator_connect_client.h
index fe6ad82a7e29d4589758b94016f3633fdaf76e17..9cc66ec716309c0f4e209facea84abd4a36e3254 100644
--- a/content/common/navigator_connect_types.h
+++ b/content/public/common/navigator_connect_client.h
@@ -2,28 +2,32 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CONTENT_COMMON_NAVIGATOR_CONNECT_TYPES_H_
-#define CONTENT_COMMON_NAVIGATOR_CONNECT_TYPES_H_
+#ifndef CONTENT_PUBLIC_COMMON_NAVIGATOR_CONNECT_CLIENT_H_
+#define CONTENT_PUBLIC_COMMON_NAVIGATOR_CONNECT_CLIENT_H_
#include "url/gurl.h"
-// This file is to have common definitions that are to be shared by
-// browser and child process.
-
namespace content {
-struct CrossOriginServiceWorkerClient {
- CrossOriginServiceWorkerClient();
- CrossOriginServiceWorkerClient(const GURL& target_url,
- const GURL& origin,
- int message_port_id);
- ~CrossOriginServiceWorkerClient();
+// This struct represents a connection to a navigator.connect exposed service.
+struct NavigatorConnectClient {
+ NavigatorConnectClient();
+ NavigatorConnectClient(const GURL& target_url,
+ const GURL& origin,
+ int message_port_id);
+ ~NavigatorConnectClient();
+ // The URL this client is connected to (or trying to connect to).
GURL target_url;
+
+ // The origin of the client.
GURL origin;
+
+ // Message port ID for the service side message port associated with this
+ // client.
int message_port_id;
};
} // namespace content
-#endif // CONTENT_COMMON_NAVIGATOR_CONNECT_TYPES_H_
+#endif // CONTENT_PUBLIC_COMMON_NAVIGATOR_CONNECT_CLIENT_H_
« no previous file with comments | « content/public/browser/navigator_connect_service_factory.h ('k') | content/public/common/navigator_connect_client.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698