common_param_traits_macros.h revision 2a99a7e74a7f215066514fe81d2bfa6639d9eddd
1// Copyright (c) 2012 The Chromium Authors. All rights reserved. 2// Use of this source code is governed by a BSD-style license that can be 3// found in the LICENSE file. 4 5// Singly or Multiply-included shared traits file depending on circumstances. 6// This allows the use of IPC serialization macros in more than one IPC message 7// file. 8#ifndef CONTENT_PUBLIC_COMMON_COMMON_PARAM_TRAITS_MACROS_H_ 9#define CONTENT_PUBLIC_COMMON_COMMON_PARAM_TRAITS_MACROS_H_ 10 11#include "content/public/common/console_message_level.h" 12#include "content/public/common/page_transition_types.h" 13#include "content/public/common/password_form.h" 14#include "content/public/common/security_style.h" 15#include "content/public/common/ssl_status.h" 16#include "ipc/ipc_message_macros.h" 17#include "net/base/request_priority.h" 18#include "third_party/WebKit/Source/Platform/chromium/public/WebPoint.h" 19#include "third_party/WebKit/Source/Platform/chromium/public/WebRect.h" 20#include "third_party/WebKit/Source/Platform/chromium/public/WebReferrerPolicy.h" 21#include "third_party/WebKit/Source/Platform/chromium/public/WebURLRequest.h" 22#include "ui/base/window_open_disposition.h" 23#include "webkit/glue/webpreferences.h" 24#include "webkit/plugins/webplugininfo.h" 25 26#undef IPC_MESSAGE_EXPORT 27#define IPC_MESSAGE_EXPORT CONTENT_EXPORT 28 29IPC_ENUM_TRAITS(content::ConsoleMessageLevel) 30IPC_ENUM_TRAITS(content::PageTransition) 31IPC_ENUM_TRAITS(content::SecurityStyle) 32IPC_ENUM_TRAITS(WebKit::WebReferrerPolicy) 33IPC_ENUM_TRAITS(WindowOpenDisposition) 34IPC_ENUM_TRAITS(webkit_glue::WebPreferences::EditingBehavior) 35IPC_ENUM_TRAITS(content::PasswordForm::Type) 36IPC_ENUM_TRAITS(net::RequestPriority) 37 38IPC_STRUCT_TRAITS_BEGIN(WebKit::WebPoint) 39 IPC_STRUCT_TRAITS_MEMBER(x) 40 IPC_STRUCT_TRAITS_MEMBER(y) 41IPC_STRUCT_TRAITS_END() 42 43IPC_STRUCT_TRAITS_BEGIN(WebKit::WebRect) 44 IPC_STRUCT_TRAITS_MEMBER(x) 45 IPC_STRUCT_TRAITS_MEMBER(y) 46 IPC_STRUCT_TRAITS_MEMBER(width) 47 IPC_STRUCT_TRAITS_MEMBER(height) 48IPC_STRUCT_TRAITS_END() 49 50IPC_STRUCT_TRAITS_BEGIN(content::PasswordForm) 51IPC_STRUCT_TRAITS_MEMBER(signon_realm) 52IPC_STRUCT_TRAITS_MEMBER(origin) 53IPC_STRUCT_TRAITS_MEMBER(action) 54IPC_STRUCT_TRAITS_MEMBER(submit_element) 55IPC_STRUCT_TRAITS_MEMBER(username_element) 56IPC_STRUCT_TRAITS_MEMBER(username_value) 57IPC_STRUCT_TRAITS_MEMBER(password_element) 58IPC_STRUCT_TRAITS_MEMBER(password_value) 59IPC_STRUCT_TRAITS_MEMBER(password_autocomplete_set) 60IPC_STRUCT_TRAITS_MEMBER(old_password_element) 61IPC_STRUCT_TRAITS_MEMBER(old_password_value) 62IPC_STRUCT_TRAITS_MEMBER(ssl_valid) 63IPC_STRUCT_TRAITS_MEMBER(preferred) 64IPC_STRUCT_TRAITS_MEMBER(blacklisted_by_user) 65IPC_STRUCT_TRAITS_MEMBER(type) 66IPC_STRUCT_TRAITS_END() 67 68IPC_STRUCT_TRAITS_BEGIN(content::SSLStatus) 69 IPC_STRUCT_TRAITS_MEMBER(security_style) 70 IPC_STRUCT_TRAITS_MEMBER(cert_id) 71 IPC_STRUCT_TRAITS_MEMBER(cert_status) 72 IPC_STRUCT_TRAITS_MEMBER(security_bits) 73 IPC_STRUCT_TRAITS_MEMBER(connection_status) 74 IPC_STRUCT_TRAITS_MEMBER(content_status) 75IPC_STRUCT_TRAITS_END() 76 77IPC_STRUCT_TRAITS_BEGIN(webkit::WebPluginMimeType) 78 IPC_STRUCT_TRAITS_MEMBER(mime_type) 79 IPC_STRUCT_TRAITS_MEMBER(file_extensions) 80 IPC_STRUCT_TRAITS_MEMBER(description) 81 IPC_STRUCT_TRAITS_MEMBER(additional_param_names) 82 IPC_STRUCT_TRAITS_MEMBER(additional_param_values) 83IPC_STRUCT_TRAITS_END() 84 85IPC_STRUCT_TRAITS_BEGIN(webkit::WebPluginInfo) 86 IPC_STRUCT_TRAITS_MEMBER(name) 87 IPC_STRUCT_TRAITS_MEMBER(path) 88 IPC_STRUCT_TRAITS_MEMBER(version) 89 IPC_STRUCT_TRAITS_MEMBER(desc) 90 IPC_STRUCT_TRAITS_MEMBER(mime_types) 91 IPC_STRUCT_TRAITS_MEMBER(type) 92 IPC_STRUCT_TRAITS_MEMBER(pepper_permissions) 93IPC_STRUCT_TRAITS_END() 94 95IPC_STRUCT_TRAITS_BEGIN(webkit_glue::WebPreferences) 96 IPC_STRUCT_TRAITS_MEMBER(standard_font_family_map) 97 IPC_STRUCT_TRAITS_MEMBER(fixed_font_family_map) 98 IPC_STRUCT_TRAITS_MEMBER(serif_font_family_map) 99 IPC_STRUCT_TRAITS_MEMBER(sans_serif_font_family_map) 100 IPC_STRUCT_TRAITS_MEMBER(cursive_font_family_map) 101 IPC_STRUCT_TRAITS_MEMBER(fantasy_font_family_map) 102 IPC_STRUCT_TRAITS_MEMBER(default_font_size) 103 IPC_STRUCT_TRAITS_MEMBER(default_fixed_font_size) 104 IPC_STRUCT_TRAITS_MEMBER(apply_default_device_scale_factor_in_compositor) 105 IPC_STRUCT_TRAITS_MEMBER(apply_page_scale_factor_in_compositor) 106 IPC_STRUCT_TRAITS_MEMBER(minimum_font_size) 107 IPC_STRUCT_TRAITS_MEMBER(minimum_logical_font_size) 108 IPC_STRUCT_TRAITS_MEMBER(default_encoding) 109 IPC_STRUCT_TRAITS_MEMBER(javascript_enabled) 110 IPC_STRUCT_TRAITS_MEMBER(web_security_enabled) 111 IPC_STRUCT_TRAITS_MEMBER(javascript_can_open_windows_automatically) 112 IPC_STRUCT_TRAITS_MEMBER(loads_images_automatically) 113 IPC_STRUCT_TRAITS_MEMBER(images_enabled) 114 IPC_STRUCT_TRAITS_MEMBER(plugins_enabled) 115 IPC_STRUCT_TRAITS_MEMBER(dom_paste_enabled) 116 IPC_STRUCT_TRAITS_MEMBER(developer_extras_enabled) 117 IPC_STRUCT_TRAITS_MEMBER(inspector_settings) 118 IPC_STRUCT_TRAITS_MEMBER(site_specific_quirks_enabled) 119 IPC_STRUCT_TRAITS_MEMBER(shrinks_standalone_images_to_fit) 120 IPC_STRUCT_TRAITS_MEMBER(uses_universal_detector) 121 IPC_STRUCT_TRAITS_MEMBER(text_areas_are_resizable) 122 IPC_STRUCT_TRAITS_MEMBER(java_enabled) 123 IPC_STRUCT_TRAITS_MEMBER(allow_scripts_to_close_windows) 124 IPC_STRUCT_TRAITS_MEMBER(uses_page_cache) 125 IPC_STRUCT_TRAITS_MEMBER(page_cache_supports_plugins) 126 IPC_STRUCT_TRAITS_MEMBER(remote_fonts_enabled) 127 IPC_STRUCT_TRAITS_MEMBER(javascript_can_access_clipboard) 128 IPC_STRUCT_TRAITS_MEMBER(xss_auditor_enabled) 129 IPC_STRUCT_TRAITS_MEMBER(dns_prefetching_enabled) 130 IPC_STRUCT_TRAITS_MEMBER(local_storage_enabled) 131 IPC_STRUCT_TRAITS_MEMBER(databases_enabled) 132 IPC_STRUCT_TRAITS_MEMBER(application_cache_enabled) 133 IPC_STRUCT_TRAITS_MEMBER(tabs_to_links) 134 IPC_STRUCT_TRAITS_MEMBER(hyperlink_auditing_enabled) 135 IPC_STRUCT_TRAITS_MEMBER(is_online) 136 IPC_STRUCT_TRAITS_MEMBER(user_style_sheet_enabled) 137 IPC_STRUCT_TRAITS_MEMBER(user_style_sheet_location) 138 IPC_STRUCT_TRAITS_MEMBER(author_and_user_styles_enabled) 139 IPC_STRUCT_TRAITS_MEMBER(frame_flattening_enabled) 140 IPC_STRUCT_TRAITS_MEMBER(allow_universal_access_from_file_urls) 141 IPC_STRUCT_TRAITS_MEMBER(allow_file_access_from_file_urls) 142 IPC_STRUCT_TRAITS_MEMBER(webaudio_enabled) 143 IPC_STRUCT_TRAITS_MEMBER(experimental_webgl_enabled) 144 IPC_STRUCT_TRAITS_MEMBER(flash_3d_enabled) 145 IPC_STRUCT_TRAITS_MEMBER(flash_stage3d_enabled) 146 IPC_STRUCT_TRAITS_MEMBER(flash_stage3d_baseline_enabled) 147 IPC_STRUCT_TRAITS_MEMBER(gl_multisampling_enabled) 148 IPC_STRUCT_TRAITS_MEMBER(privileged_webgl_extensions_enabled) 149 IPC_STRUCT_TRAITS_MEMBER(webgl_errors_to_console_enabled) 150 IPC_STRUCT_TRAITS_MEMBER(accelerated_compositing_for_overflow_scroll_enabled) 151 IPC_STRUCT_TRAITS_MEMBER( 152 accelerated_compositing_for_scrollable_frames_enabled) 153 IPC_STRUCT_TRAITS_MEMBER(composited_scrolling_for_frames_enabled) 154 IPC_STRUCT_TRAITS_MEMBER(mock_scrollbars_enabled) 155 IPC_STRUCT_TRAITS_MEMBER(threaded_html_parser) 156 IPC_STRUCT_TRAITS_MEMBER(show_paint_rects) 157 IPC_STRUCT_TRAITS_MEMBER(asynchronous_spell_checking_enabled) 158 IPC_STRUCT_TRAITS_MEMBER(unified_textchecker_enabled) 159 IPC_STRUCT_TRAITS_MEMBER(accelerated_compositing_enabled) 160 IPC_STRUCT_TRAITS_MEMBER(force_compositing_mode) 161 IPC_STRUCT_TRAITS_MEMBER(accelerated_2d_canvas_enabled) 162 IPC_STRUCT_TRAITS_MEMBER(minimum_accelerated_2d_canvas_size) 163 IPC_STRUCT_TRAITS_MEMBER(antialiased_2d_canvas_disabled) 164 IPC_STRUCT_TRAITS_MEMBER(accelerated_filters_enabled) 165 IPC_STRUCT_TRAITS_MEMBER(gesture_tap_highlight_enabled) 166 IPC_STRUCT_TRAITS_MEMBER(accelerated_compositing_for_plugins_enabled) 167 IPC_STRUCT_TRAITS_MEMBER(accelerated_compositing_for_3d_transforms_enabled) 168 IPC_STRUCT_TRAITS_MEMBER(accelerated_compositing_for_animation_enabled) 169 IPC_STRUCT_TRAITS_MEMBER(accelerated_compositing_for_video_enabled) 170 IPC_STRUCT_TRAITS_MEMBER(memory_info_enabled) 171 IPC_STRUCT_TRAITS_MEMBER(fullscreen_enabled) 172 IPC_STRUCT_TRAITS_MEMBER(allow_displaying_insecure_content) 173 IPC_STRUCT_TRAITS_MEMBER(allow_running_insecure_content) 174 IPC_STRUCT_TRAITS_MEMBER(enable_scroll_animator) 175 IPC_STRUCT_TRAITS_MEMBER(visual_word_movement_enabled) 176 IPC_STRUCT_TRAITS_MEMBER(password_echo_enabled) 177 IPC_STRUCT_TRAITS_MEMBER(css_sticky_position_enabled) 178 IPC_STRUCT_TRAITS_MEMBER(css_shaders_enabled) 179 IPC_STRUCT_TRAITS_MEMBER(css_variables_enabled) 180 IPC_STRUCT_TRAITS_MEMBER(css_grid_layout_enabled) 181 IPC_STRUCT_TRAITS_MEMBER(touch_enabled) 182 IPC_STRUCT_TRAITS_MEMBER(device_supports_touch) 183 IPC_STRUCT_TRAITS_MEMBER(device_supports_mouse) 184 IPC_STRUCT_TRAITS_MEMBER(touch_adjustment_enabled) 185 IPC_STRUCT_TRAITS_MEMBER(touch_drag_drop_enabled) 186 IPC_STRUCT_TRAITS_MEMBER(fixed_position_creates_stacking_context) 187 IPC_STRUCT_TRAITS_MEMBER(sync_xhr_in_documents_enabled) 188 IPC_STRUCT_TRAITS_MEMBER(deferred_image_decoding_enabled) 189 IPC_STRUCT_TRAITS_MEMBER(should_respect_image_orientation) 190 IPC_STRUCT_TRAITS_MEMBER(number_of_cpu_cores) 191 IPC_STRUCT_TRAITS_MEMBER(editing_behavior) 192 IPC_STRUCT_TRAITS_MEMBER(supports_multiple_windows) 193 IPC_STRUCT_TRAITS_MEMBER(viewport_enabled) 194 IPC_STRUCT_TRAITS_MEMBER(initialize_at_minimum_page_scale) 195 IPC_STRUCT_TRAITS_MEMBER(smart_insert_delete_enabled) 196 IPC_STRUCT_TRAITS_MEMBER(cookie_enabled) 197 IPC_STRUCT_TRAITS_MEMBER(apply_page_scale_factor_in_compositor) 198#if defined(OS_ANDROID) 199 IPC_STRUCT_TRAITS_MEMBER(text_autosizing_enabled) 200 IPC_STRUCT_TRAITS_MEMBER(font_scale_factor) 201 IPC_STRUCT_TRAITS_MEMBER(force_enable_zoom) 202 IPC_STRUCT_TRAITS_MEMBER(double_tap_to_zoom_enabled) 203 IPC_STRUCT_TRAITS_MEMBER(user_gesture_required_for_media_playback) 204 IPC_STRUCT_TRAITS_MEMBER(default_video_poster_url) 205#endif 206IPC_STRUCT_TRAITS_END() 207 208#endif // CONTENT_PUBLIC_COMMON_COMMON_PARAM_TRAITS_MACROS_H_ 209