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

Side by Side 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, 10 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_COMMON_NAVIGATOR_CONNECT_TYPES_H_ 5 #ifndef CONTENT_PUBLIC_COMMON_NAVIGATOR_CONNECT_CLIENT_H_
6 #define CONTENT_COMMON_NAVIGATOR_CONNECT_TYPES_H_ 6 #define CONTENT_PUBLIC_COMMON_NAVIGATOR_CONNECT_CLIENT_H_
7 7
8 #include "url/gurl.h" 8 #include "url/gurl.h"
9 9
10 // This file is to have common definitions that are to be shared by
11 // browser and child process.
12
13 namespace content { 10 namespace content {
14 11
15 struct CrossOriginServiceWorkerClient { 12 // This struct represents a connection to a navigator.connect exposed service.
16 CrossOriginServiceWorkerClient(); 13 struct NavigatorConnectClient {
17 CrossOriginServiceWorkerClient(const GURL& target_url, 14 NavigatorConnectClient();
18 const GURL& origin, 15 NavigatorConnectClient(const GURL& target_url,
19 int message_port_id); 16 const GURL& origin,
20 ~CrossOriginServiceWorkerClient(); 17 int message_port_id);
18 ~NavigatorConnectClient();
21 19
20 // The URL this client is connected to (or trying to connect to).
22 GURL target_url; 21 GURL target_url;
22
23 // The origin of the client.
23 GURL origin; 24 GURL origin;
25
26 // Message port ID for the service side message port associated with this
27 // client.
24 int message_port_id; 28 int message_port_id;
25 }; 29 };
26 30
27 } // namespace content 31 } // namespace content
28 32
29 #endif // CONTENT_COMMON_NAVIGATOR_CONNECT_TYPES_H_ 33 #endif // CONTENT_PUBLIC_COMMON_NAVIGATOR_CONNECT_CLIENT_H_
OLDNEW
« 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