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

Side by Side Diff: chrome/common/render_messages.h

Issue 8538004: Take script URLs into account when applying script content settings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased. Created 9 years, 1 month 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 | Annotate | Revision Log
« no previous file with comments | « chrome/common/content_settings.cc ('k') | chrome/common/render_messages.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 <map> 6 #include <map>
7 #include <set> 7 #include <set>
8 #include <string> 8 #include <string>
9 #include <vector> 9 #include <vector>
10 10
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after
91 } 91 }
92 92
93 static void Log(const param_type& p, std::string* l) { 93 static void Log(const param_type& p, std::string* l) {
94 l->append(base::StringPrintf("<gfx::NativeView>")); 94 l->append(base::StringPrintf("<gfx::NativeView>"));
95 } 95 }
96 }; 96 };
97 97
98 #endif // defined(OS_POSIX) && !defined(USE_AURA) 98 #endif // defined(OS_POSIX) && !defined(USE_AURA)
99 99
100 template <> 100 template <>
101 struct ParamTraits<ContentSettings> {
102 typedef ContentSettings param_type;
103 static void Write(Message* m, const param_type& p);
104 static bool Read(const Message* m, void** iter, param_type* r);
105 static void Log(const param_type& p, std::string* l);
106 };
107
108 template <>
109 struct ParamTraits<ContentSettingsPattern> { 101 struct ParamTraits<ContentSettingsPattern> {
110 typedef ContentSettingsPattern param_type; 102 typedef ContentSettingsPattern param_type;
111 static void Write(Message* m, const param_type& p); 103 static void Write(Message* m, const param_type& p);
112 static bool Read(const Message* m, void** iter, param_type* r); 104 static bool Read(const Message* m, void** iter, param_type* r);
113 static void Log(const param_type& p, std::string* l); 105 static void Log(const param_type& p, std::string* l);
114 }; 106 };
115 107
116 } // namespace IPC 108 } // namespace IPC
117 109
118 #endif // CHROME_COMMON_RENDER_MESSAGES_H_ 110 #endif // CHROME_COMMON_RENDER_MESSAGES_H_
(...skipping 22 matching lines...) Expand all
141 IPC_STRUCT_TRAITS_END() 133 IPC_STRUCT_TRAITS_END()
142 134
143 IPC_STRUCT_TRAITS_BEGIN(ContentSettingPatternSource) 135 IPC_STRUCT_TRAITS_BEGIN(ContentSettingPatternSource)
144 IPC_STRUCT_TRAITS_MEMBER(primary_pattern) 136 IPC_STRUCT_TRAITS_MEMBER(primary_pattern)
145 IPC_STRUCT_TRAITS_MEMBER(secondary_pattern) 137 IPC_STRUCT_TRAITS_MEMBER(secondary_pattern)
146 IPC_STRUCT_TRAITS_MEMBER(setting) 138 IPC_STRUCT_TRAITS_MEMBER(setting)
147 IPC_STRUCT_TRAITS_MEMBER(source) 139 IPC_STRUCT_TRAITS_MEMBER(source)
148 IPC_STRUCT_TRAITS_MEMBER(incognito) 140 IPC_STRUCT_TRAITS_MEMBER(incognito)
149 IPC_STRUCT_TRAITS_END() 141 IPC_STRUCT_TRAITS_END()
150 142
143 IPC_STRUCT_TRAITS_BEGIN(RendererContentSettingRules)
144 IPC_STRUCT_TRAITS_MEMBER(image_rules)
145 IPC_STRUCT_TRAITS_MEMBER(script_rules)
146 IPC_STRUCT_TRAITS_END()
147
151 IPC_STRUCT_TRAITS_BEGIN(ThumbnailScore) 148 IPC_STRUCT_TRAITS_BEGIN(ThumbnailScore)
152 IPC_STRUCT_TRAITS_MEMBER(boring_score) 149 IPC_STRUCT_TRAITS_MEMBER(boring_score)
153 IPC_STRUCT_TRAITS_MEMBER(good_clipping) 150 IPC_STRUCT_TRAITS_MEMBER(good_clipping)
154 IPC_STRUCT_TRAITS_MEMBER(at_top) 151 IPC_STRUCT_TRAITS_MEMBER(at_top)
155 IPC_STRUCT_TRAITS_MEMBER(time_at_snapshot) 152 IPC_STRUCT_TRAITS_MEMBER(time_at_snapshot)
156 IPC_STRUCT_TRAITS_END() 153 IPC_STRUCT_TRAITS_END()
157 154
158 IPC_STRUCT_TRAITS_BEGIN(WebKit::WebCache::ResourceTypeStat) 155 IPC_STRUCT_TRAITS_BEGIN(WebKit::WebCache::ResourceTypeStat)
159 IPC_STRUCT_TRAITS_MEMBER(count) 156 IPC_STRUCT_TRAITS_MEMBER(count)
160 IPC_STRUCT_TRAITS_MEMBER(size) 157 IPC_STRUCT_TRAITS_MEMBER(size)
(...skipping 58 matching lines...) Expand 10 before | Expand all | Expand 10 after
219 216
220 // History system notification that a link has been added and the link 217 // History system notification that a link has been added and the link
221 // coloring state for the given hash must be re-calculated. 218 // coloring state for the given hash must be re-calculated.
222 IPC_MESSAGE_CONTROL1(ChromeViewMsg_VisitedLink_Add, std::vector<uint64>) 219 IPC_MESSAGE_CONTROL1(ChromeViewMsg_VisitedLink_Add, std::vector<uint64>)
223 220
224 // History system notification that one or more history items have been 221 // History system notification that one or more history items have been
225 // deleted, which at this point means that all link coloring state must be 222 // deleted, which at this point means that all link coloring state must be
226 // re-calculated. 223 // re-calculated.
227 IPC_MESSAGE_CONTROL0(ChromeViewMsg_VisitedLink_Reset) 224 IPC_MESSAGE_CONTROL0(ChromeViewMsg_VisitedLink_Reset)
228 225
229 // Set the content settings for a particular url that the renderer is in the 226 // Set the content setting rules stored by the renderer.
230 // process of loading. This will be stored, to be used if the load commits 227 IPC_MESSAGE_CONTROL1(ChromeViewMsg_SetContentSettingRules,
231 // and ignored otherwise. 228 RendererContentSettingRules /* rules */)
232 IPC_MESSAGE_ROUTED2(ChromeViewMsg_SetContentSettingsForLoadingURL,
233 GURL /* url */,
234 ContentSettings /* content_settings */)
235
236 // Set the content settings for a particular url, so all render views
237 // displaying this host url update their content settings to match.
238 IPC_MESSAGE_CONTROL2(ChromeViewMsg_SetContentSettingsForCurrentURL,
239 GURL /* url */,
240 ContentSettings /* content_settings */)
241
242 // Set the content settings for a particular url that the renderer is in the
243 // process of loading. This will be stored, to be used if the load commits
244 // and ignored otherwise.
245 IPC_MESSAGE_CONTROL1(ChromeViewMsg_SetDefaultContentSettings,
246 ContentSettings /* content_settings */)
247
248 // Set the content settings for images.
249 IPC_MESSAGE_CONTROL1(ChromeViewMsg_SetImageSettingRules,
250 ContentSettingsForOneType /* rules */)
251 229
252 // Tells the render view to load all blocked plugins. 230 // Tells the render view to load all blocked plugins.
253 IPC_MESSAGE_ROUTED0(ChromeViewMsg_LoadBlockedPlugins) 231 IPC_MESSAGE_ROUTED0(ChromeViewMsg_LoadBlockedPlugins)
254 232
255 // Asks the renderer to send back stats on the WebCore cache broken down by 233 // Asks the renderer to send back stats on the WebCore cache broken down by
256 // resource types. 234 // resource types.
257 IPC_MESSAGE_CONTROL0(ChromeViewMsg_GetCacheResourceStats) 235 IPC_MESSAGE_CONTROL0(ChromeViewMsg_GetCacheResourceStats)
258 236
259 // Asks the renderer to send back Histograms. 237 // Asks the renderer to send back Histograms.
260 IPC_MESSAGE_CONTROL1(ChromeViewMsg_GetRendererHistograms, 238 IPC_MESSAGE_CONTROL1(ChromeViewMsg_GetRendererHistograms,
(...skipping 358 matching lines...) Expand 10 before | Expand all | Expand 10 after
619 // previous SetCookie message to be processed. 597 // previous SetCookie message to be processed.
620 IPC_SYNC_MESSAGE_ROUTED2_1(ChromeViewHostMsg_GetCookies, 598 IPC_SYNC_MESSAGE_ROUTED2_1(ChromeViewHostMsg_GetCookies,
621 GURL /* url */, 599 GURL /* url */,
622 GURL /* first_party_for_cookies */, 600 GURL /* first_party_for_cookies */,
623 std::string /* cookies */) 601 std::string /* cookies */)
624 602
625 // Provide the browser process with current renderer framerate. 603 // Provide the browser process with current renderer framerate.
626 IPC_MESSAGE_CONTROL2(ChromeViewHostMsg_FPS, 604 IPC_MESSAGE_CONTROL2(ChromeViewHostMsg_FPS,
627 int /* routing id */, 605 int /* routing id */,
628 float /* frames per second */) 606 float /* frames per second */)
OLDNEW
« no previous file with comments | « chrome/common/content_settings.cc ('k') | chrome/common/render_messages.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698