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

Side by Side Diff: components/network_hints/common/network_hints_messages.h

Issue 2043083002: Speculatively launch Service Workers on mouse/touch events. [2/5] (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: revert BUILD.gn Created 4 years, 5 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 // Multiply-included file, no traditional include guard. 5 // Multiply-included file, no traditional include guard.
6 #include <string> 6 #include <string>
7 #include <vector> 7 #include <vector>
8 8
9 #include "components/network_hints/common/network_hints_common.h" 9 #include "components/network_hints/common/network_hints_common.h"
10 #include "ipc/ipc_message_macros.h" 10 #include "ipc/ipc_message_macros.h"
11 #include "ipc/ipc_message_utils.h" 11 #include "ipc/ipc_message_utils.h"
12 #include "third_party/WebKit/public/platform/WebNavigationHintType.h"
12 #include "url/ipc/url_param_traits.h" 13 #include "url/ipc/url_param_traits.h"
13 14
14 // Singly-included section for custom IPC traits. 15 // Singly-included section for custom IPC traits.
15 #ifndef COMPONENTS_NETWORK_HINTS_COMMON_NETWORK_HINTS_MESSAGES_H_ 16 #ifndef COMPONENTS_NETWORK_HINTS_COMMON_NETWORK_HINTS_MESSAGES_H_
16 #define COMPONENTS_NETWORK_HINTS_COMMON_NETWORK_HINTS_MESSAGES_H_ 17 #define COMPONENTS_NETWORK_HINTS_COMMON_NETWORK_HINTS_MESSAGES_H_
17 18
18 namespace IPC { 19 namespace IPC {
19 20
20 template <> 21 template <>
21 struct ParamTraits<network_hints::LookupRequest> { 22 struct ParamTraits<network_hints::LookupRequest> {
22 typedef network_hints::LookupRequest param_type; 23 typedef network_hints::LookupRequest param_type;
23 static void Write(base::Pickle* m, const param_type& p); 24 static void Write(base::Pickle* m, const param_type& p);
24 static bool Read(const base::Pickle* m, 25 static bool Read(const base::Pickle* m,
25 base::PickleIterator* iter, 26 base::PickleIterator* iter,
26 param_type* r); 27 param_type* r);
27 static void Log(const param_type& p, std::string* l); 28 static void Log(const param_type& p, std::string* l);
28 }; 29 };
29 30
30 } // namespace IPC 31 } // namespace IPC
31 32
32 #endif // COMPONENTS_NETWORK_HINTS_COMMON_NETWORK_HINTS_MESSAGES_H_ 33 #endif // COMPONENTS_NETWORK_HINTS_COMMON_NETWORK_HINTS_MESSAGES_H_
33 34
34 #define IPC_MESSAGE_START NetworkHintsMsgStart 35 #define IPC_MESSAGE_START NetworkHintsMsgStart
35 36
37 IPC_ENUM_TRAITS_MAX_VALUE(blink::WebNavigationHintType,
38 blink::WebNavigationHintType::Last)
39
36 //----------------------------------------------------------------------------- 40 //-----------------------------------------------------------------------------
37 // Host messages 41 // Host messages
38 // These are messages sent from the renderer process to the browser process. 42 // These are messages sent from the renderer process to the browser process.
39 43
40 // Request for a DNS prefetch of the names in the array. 44 // Request for a DNS prefetch of the names in the array.
41 // NameList is typedef'ed std::vector<std::string> 45 // NameList is typedef'ed std::vector<std::string>
42 IPC_MESSAGE_CONTROL1(NetworkHintsMsg_DNSPrefetch, 46 IPC_MESSAGE_CONTROL1(NetworkHintsMsg_DNSPrefetch,
43 network_hints::LookupRequest) 47 network_hints::LookupRequest)
44 48
45 49
46 // Request for preconnect to host providing resource specified by URL 50 // Request for preconnect to host providing resource specified by URL
47 IPC_MESSAGE_CONTROL3(NetworkHintsMsg_Preconnect, 51 IPC_MESSAGE_CONTROL3(NetworkHintsMsg_Preconnect,
48 GURL /* preconnect target url */, 52 GURL /* preconnect target url */,
49 bool /* Does connection have its credentials flag set */, 53 bool /* Does connection have its credentials flag set */,
50 int /* number of connections */) 54 int /* number of connections */)
55
56 // Request to trigger possible optimizations for navigation.
57 IPC_MESSAGE_CONTROL2(NetworkHintsMsg_NavigationHint,
58 GURL /* document url */,
59 blink::WebNavigationHintType /* navigation hint type */)
OLDNEW
« no previous file with comments | « components/network_hints/common/OWNERS ('k') | components/network_hints/renderer/prescient_networking_dispatcher.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698