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

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

Issue 7104029: Automation: fix chrome/browser dependency on chrome/test headers. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 years, 6 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 | Annotate | Revision Log
« no previous file with comments | « chrome/common/automation_constants.h ('k') | chrome/common/automation_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 message file, no traditional include guard. 5 // Multiply-included message file, no traditional include guard.
6 #include <string> 6 #include <string>
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "chrome/common/automation_constants.h" 9 #include "chrome/common/automation_constants.h"
10 #include "chrome/common/content_settings.h" 10 #include "chrome/common/content_settings.h"
11 #include "content/common/common_param_traits.h" 11 #include "content/common/common_param_traits.h"
12 #include "content/common/page_type.h" 12 #include "content/common/page_type.h"
13 #include "content/common/security_style.h" 13 #include "content/common/security_style.h"
14 #include "content/common/webkit_param_traits.h" 14 #include "content/common/webkit_param_traits.h"
15 #include "ipc/ipc_message_macros.h" 15 #include "ipc/ipc_message_macros.h"
16 #include "ipc/ipc_message_utils.h" 16 #include "ipc/ipc_message_utils.h"
17 #include "net/base/host_port_pair.h" 17 #include "net/base/host_port_pair.h"
18 #include "net/base/upload_data.h" 18 #include "net/base/upload_data.h"
19 #include "ui/gfx/rect.h" 19 #include "ui/gfx/rect.h"
20 20
21 // Singly-included section, not yet converted. 21 // Singly-included section, not yet converted.
22 #ifndef CHROME_COMMON_AUTOMATION_MESSAGES_H__ 22 #ifndef CHROME_COMMON_AUTOMATION_MESSAGES_H__
23 #define CHROME_COMMON_AUTOMATION_MESSAGES_H__ 23 #define CHROME_COMMON_AUTOMATION_MESSAGES_H__
24 24
25 struct AutocompleteMatch;
26
25 struct AutomationMsg_Find_Params { 27 struct AutomationMsg_Find_Params {
26 // Unused value, which exists only for backwards compat. 28 // Unused value, which exists only for backwards compat.
27 int unused; 29 int unused;
28 30
29 // The word(s) to find on the page. 31 // The word(s) to find on the page.
30 string16 search_string; 32 string16 search_string;
31 33
32 // Whether to search forward or backward within the page. 34 // Whether to search forward or backward within the page.
33 bool forward; 35 bool forward;
34 36
(...skipping 160 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 197
196 std::string url; 198 std::string url;
197 std::string method; 199 std::string method;
198 std::string referrer; 200 std::string referrer;
199 std::string extra_request_headers; 201 std::string extra_request_headers;
200 scoped_refptr<net::UploadData> upload_data; 202 scoped_refptr<net::UploadData> upload_data;
201 int resource_type; // see webkit/glue/resource_type.h 203 int resource_type; // see webkit/glue/resource_type.h
202 int load_flags; // see net/base/load_flags.h 204 int load_flags; // see net/base/load_flags.h
203 }; 205 };
204 206
207 // The purpose of this class is to act as a serializable version of
208 // AutocompleteMatch. The reason for this class is because we don't want to
209 // serialize all elements of AutocompleteMatch and we want some data from the
210 // autocomplete provider without the hassle of serializing it.
211 struct AutocompleteMatchData {
Peter Kasting 2011/06/01 20:28:33 Nit: This used to have a constructor. It might be
Paweł Hajdan Jr. 2011/06/01 20:30:03 The constructor can't be in chrome/common because
Peter Kasting 2011/06/01 21:05:52 Then we should move AutocompleteMatch to chrome/co
212 std::string provider_name;
213 int relevance;
214 bool deletable;
215 string16 fill_into_edit;
216 size_t inline_autocomplete_offset;
217 GURL destination_url;
218 string16 contents;
219 string16 description;
220 bool is_history_what_you_typed_match;
221 std::string type;
222 bool starred;
223 };
224
205 namespace IPC { 225 namespace IPC {
206 226
207 template <> 227 template <>
208 struct ParamTraits<AutomationMsg_Find_Params> { 228 struct ParamTraits<AutomationMsg_Find_Params> {
209 typedef AutomationMsg_Find_Params param_type; 229 typedef AutomationMsg_Find_Params param_type;
210 static void Write(Message* m, const param_type& p); 230 static void Write(Message* m, const param_type& p);
211 static bool Read(const Message* m, void** iter, param_type* p); 231 static bool Read(const Message* m, void** iter, param_type* p);
212 static void Log(const param_type& p, std::string* l); 232 static void Log(const param_type& p, std::string* l);
213 }; 233 };
214 234
(...skipping 135 matching lines...) Expand 10 before | Expand all | Expand 10 after
350 }; 370 };
351 371
352 template <> 372 template <>
353 struct ParamTraits<AttachExternalTabParams> { 373 struct ParamTraits<AttachExternalTabParams> {
354 typedef AttachExternalTabParams param_type; 374 typedef AttachExternalTabParams param_type;
355 static void Write(Message* m, const param_type& p); 375 static void Write(Message* m, const param_type& p);
356 static bool Read(const Message* m, void** iter, param_type* p); 376 static bool Read(const Message* m, void** iter, param_type* p);
357 static void Log(const param_type& p, std::string* l); 377 static void Log(const param_type& p, std::string* l);
358 }; 378 };
359 379
380 template <>
381 struct ParamTraits<AutocompleteMatchData> {
382 typedef AutocompleteMatchData param_type;
383 static void Write(Message* m, const param_type& p);
384 static bool Read(const Message* m, void** iter, param_type* r);
385 static void Log(const param_type& p, std::string* l);
386 };
387
360 } // namespace IPC 388 } // namespace IPC
361 389
362 #endif // CHROME_COMMON_AUTOMATION_MESSAGES_H__ 390 #endif // CHROME_COMMON_AUTOMATION_MESSAGES_H__
363 391
364 // Keep this internal message file unchanged to preserve line numbering 392 // Keep this internal message file unchanged to preserve line numbering
365 // (and hence the dubious __LINE__-based message numberings) across versions. 393 // (and hence the dubious __LINE__-based message numberings) across versions.
366 #include "chrome/common/automation_messages_internal.h" 394 #include "chrome/common/automation_messages_internal.h"
367 395
OLDNEW
« no previous file with comments | « chrome/common/automation_constants.h ('k') | chrome/common/automation_messages.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698