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

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

Issue 5722003: Make DOMStorageDispatcherHost be a message filter (and rename it accordingly)... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: get rid of _DELAY_HANDLE macro Created 10 years 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
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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 CHROME_COMMON_RENDER_MESSAGES_H_ 5 #ifndef CHROME_COMMON_RENDER_MESSAGES_H_
6 #define CHROME_COMMON_RENDER_MESSAGES_H_ 6 #define CHROME_COMMON_RENDER_MESSAGES_H_
7 #pragma once 7 #pragma once
8 8
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
11 11
12 // TODO(erg): This list has been temporarily annotated by erg while doing work 12 // TODO(erg): This list has been temporarily annotated by erg while doing work
13 // on which headers to pull out. 13 // on which headers to pull out.
14 #include "app/clipboard/clipboard.h" // enum 14 #include "app/clipboard/clipboard.h" // enum
15 #include "base/basictypes.h" 15 #include "base/basictypes.h"
16 #include "base/ref_counted.h" 16 #include "base/ref_counted.h"
17 #include "base/string16.h" 17 #include "base/string16.h"
18 #include "chrome/common/common_param_traits.h" 18 #include "chrome/common/common_param_traits.h"
19 #include "chrome/common/css_colors.h" 19 #include "chrome/common/css_colors.h"
20 #include "chrome/common/dom_storage_common.h"
21 #include "chrome/common/indexed_db_param_traits.h" 20 #include "chrome/common/indexed_db_param_traits.h"
22 #include "chrome/common/page_transition_types.h" 21 #include "chrome/common/page_transition_types.h"
23 #include "chrome/common/translate_errors.h" 22 #include "chrome/common/translate_errors.h"
24 #include "chrome/common/view_types.h" 23 #include "chrome/common/view_types.h"
25 #include "chrome/common/webkit_param_traits.h" 24 #include "chrome/common/webkit_param_traits.h"
26 #include "ipc/ipc_message_utils.h" 25 #include "ipc/ipc_message_utils.h"
27 #include "ipc/ipc_platform_file.h" // ifdefed typedef. 26 #include "ipc/ipc_platform_file.h" // ifdefed typedef.
28 #include "third_party/WebKit/WebKit/chromium/public/WebStorageArea.h"
29 #include "webkit/appcache/appcache_interfaces.h" // enum appcache::Status 27 #include "webkit/appcache/appcache_interfaces.h" // enum appcache::Status
30 #include "webkit/fileapi/file_system_types.h" // enum fileapi::FileSystemType 28 #include "webkit/fileapi/file_system_types.h" // enum fileapi::FileSystemType
31 #include "webkit/glue/plugins/pepper_dir_contents.h" 29 #include "webkit/glue/plugins/pepper_dir_contents.h"
32 30
33 #if defined(OS_MACOSX) 31 #if defined(OS_MACOSX)
34 struct FontDescriptor; 32 struct FontDescriptor;
35 #endif 33 #endif
36 34
37 namespace appcache { 35 namespace appcache {
38 struct AppCacheInfo; 36 struct AppCacheInfo;
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
96 struct ViewHostMsg_UpdateRect_Params; 94 struct ViewHostMsg_UpdateRect_Params;
97 struct ViewMsg_ClosePage_Params; 95 struct ViewMsg_ClosePage_Params;
98 struct ViewHostMsg_Resource_Request; 96 struct ViewHostMsg_Resource_Request;
99 struct ViewMsg_Print_Params; 97 struct ViewMsg_Print_Params;
100 struct ViewMsg_PrintPage_Params; 98 struct ViewMsg_PrintPage_Params;
101 struct ViewMsg_PrintPages_Params; 99 struct ViewMsg_PrintPages_Params;
102 struct ViewHostMsg_DidPrintPage_Params; 100 struct ViewHostMsg_DidPrintPage_Params;
103 struct ViewHostMsg_Audio_CreateStream_Params; 101 struct ViewHostMsg_Audio_CreateStream_Params;
104 struct ViewHostMsg_ShowPopup_Params; 102 struct ViewHostMsg_ShowPopup_Params;
105 struct ViewHostMsg_ScriptedPrint_Params; 103 struct ViewHostMsg_ScriptedPrint_Params;
106 struct ViewMsg_DOMStorageEvent_Params;
107 struct ViewHostMsg_IDBFactoryOpen_Params; 104 struct ViewHostMsg_IDBFactoryOpen_Params;
108 struct ViewHostMsg_IDBDatabaseCreateObjectStore_Params; 105 struct ViewHostMsg_IDBDatabaseCreateObjectStore_Params;
109 struct ViewHostMsg_IDBIndexOpenCursor_Params; 106 struct ViewHostMsg_IDBIndexOpenCursor_Params;
110 struct ViewHostMsg_IDBObjectStoreCreateIndex_Params; 107 struct ViewHostMsg_IDBObjectStoreCreateIndex_Params;
111 struct ViewHostMsg_IDBObjectStoreOpenCursor_Params; 108 struct ViewHostMsg_IDBObjectStoreOpenCursor_Params;
112 struct ViewHostMsg_IDBObjectStorePut_Params; 109 struct ViewHostMsg_IDBObjectStorePut_Params;
113 struct ViewMsg_ExecuteCode_Params; 110 struct ViewMsg_ExecuteCode_Params;
114 struct ViewHostMsg_CreateWorker_Params; 111 struct ViewHostMsg_CreateWorker_Params;
115 struct ViewHostMsg_ShowNotification_Params; 112 struct ViewHostMsg_ShowNotification_Params;
116 struct ViewMsg_New_Params; 113 struct ViewMsg_New_Params;
(...skipping 356 matching lines...) Expand 10 before | Expand all | Expand 10 after
473 470
474 // Traits for EditCommand structure. 471 // Traits for EditCommand structure.
475 template <> 472 template <>
476 struct ParamTraits<EditCommand> { 473 struct ParamTraits<EditCommand> {
477 typedef EditCommand param_type; 474 typedef EditCommand param_type;
478 static void Write(Message* m, const param_type& p); 475 static void Write(Message* m, const param_type& p);
479 static bool Read(const Message* m, void** iter, param_type* p); 476 static bool Read(const Message* m, void** iter, param_type* p);
480 static void Log(const param_type& p, std::string* l); 477 static void Log(const param_type& p, std::string* l);
481 }; 478 };
482 479
483 // Traits for DOMStorageType enum.
484 template <>
485 struct ParamTraits<DOMStorageType> {
486 typedef DOMStorageType param_type;
487 static void Write(Message* m, const param_type& p) {
488 m->WriteInt(p);
489 }
490 static bool Read(const Message* m, void** iter, param_type* p) {
491 int type;
492 if (!m->ReadInt(iter, &type))
493 return false;
494 *p = static_cast<param_type>(type);
495 return true;
496 }
497 static void Log(const param_type& p, std::string* l) {
498 std::string control;
499 switch (p) {
500 case DOM_STORAGE_LOCAL:
501 control = "DOM_STORAGE_LOCAL";
502 break;
503 case DOM_STORAGE_SESSION:
504 control = "DOM_STORAGE_SESSION";
505 break;
506 default:
507 NOTIMPLEMENTED();
508 control = "UNKNOWN";
509 break;
510 }
511 LogParam(control, l);
512 }
513 };
514
515 // Traits for WebKit::WebStorageArea::Result enum.
516 template <>
517 struct ParamTraits<WebKit::WebStorageArea::Result> {
518 typedef WebKit::WebStorageArea::Result param_type;
519 static void Write(Message* m, const param_type& p) {
520 m->WriteInt(p);
521 }
522 static bool Read(const Message* m, void** iter, param_type* p) {
523 int type;
524 if (!m->ReadInt(iter, &type))
525 return false;
526 *p = static_cast<param_type>(type);
527 return true;
528 }
529 static void Log(const param_type& p, std::string* l) {
530 std::string control;
531 switch (p) {
532 case WebKit::WebStorageArea::ResultOK:
533 control = "WebKit::WebStorageArea::ResultOK";
534 break;
535 case WebKit::WebStorageArea::ResultBlockedByQuota:
536 control = "WebKit::WebStorageArea::ResultBlockedByQuota";
537 break;
538 case WebKit::WebStorageArea::ResultBlockedByPolicy:
539 control = "WebKit::WebStorageArea::ResultBlockedByPolicy";
540 break;
541 default:
542 NOTIMPLEMENTED();
543 control = "UNKNOWN";
544 break;
545 }
546 LogParam(control, l);
547 }
548 };
549
550 // Traits for WebCookie 480 // Traits for WebCookie
551 template <> 481 template <>
552 struct ParamTraits<webkit_glue::WebCookie> { 482 struct ParamTraits<webkit_glue::WebCookie> {
553 typedef webkit_glue::WebCookie param_type; 483 typedef webkit_glue::WebCookie param_type;
554 static void Write(Message* m, const param_type& p); 484 static void Write(Message* m, const param_type& p);
555 static bool Read(const Message* m, void** iter, param_type* p); 485 static bool Read(const Message* m, void** iter, param_type* p);
556 static void Log(const param_type& p, std::string* l); 486 static void Log(const param_type& p, std::string* l);
557 }; 487 };
558 488
559 template <> 489 template <>
(...skipping 76 matching lines...) Expand 10 before | Expand all | Expand 10 after
636 static void Write(Message* m, const param_type& p); 566 static void Write(Message* m, const param_type& p);
637 static bool Read(const Message* m, void** iter, param_type* p); 567 static bool Read(const Message* m, void** iter, param_type* p);
638 static void Log(const param_type& p, std::string* l); 568 static void Log(const param_type& p, std::string* l);
639 }; 569 };
640 570
641 } // namespace IPC 571 } // namespace IPC
642 572
643 #include "chrome/common/render_messages_internal.h" 573 #include "chrome/common/render_messages_internal.h"
644 574
645 #endif // CHROME_COMMON_RENDER_MESSAGES_H_ 575 #endif // CHROME_COMMON_RENDER_MESSAGES_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698