| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 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 | 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 #include "content/renderer/render_view_impl.h" | 5 #include "content/renderer/render_view_impl.h" |
| 6 | 6 |
| 7 #include <algorithm> | 7 #include <algorithm> |
| 8 #include <cmath> | 8 #include <cmath> |
| 9 | 9 |
| 10 #include "base/auto_reset.h" | 10 #include "base/auto_reset.h" |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 111 #include "content/renderer/resizing_mode_selector.h" | 111 #include "content/renderer/resizing_mode_selector.h" |
| 112 #include "content/renderer/savable_resources.h" | 112 #include "content/renderer/savable_resources.h" |
| 113 #include "content/renderer/skia_benchmarking_extension.h" | 113 #include "content/renderer/skia_benchmarking_extension.h" |
| 114 #include "content/renderer/speech_recognition_dispatcher.h" | 114 #include "content/renderer/speech_recognition_dispatcher.h" |
| 115 #include "content/renderer/stats_collection_controller.h" | 115 #include "content/renderer/stats_collection_controller.h" |
| 116 #include "content/renderer/stats_collection_observer.h" | 116 #include "content/renderer/stats_collection_observer.h" |
| 117 #include "content/renderer/text_input_client_observer.h" | 117 #include "content/renderer/text_input_client_observer.h" |
| 118 #include "content/renderer/v8_value_converter_impl.h" | 118 #include "content/renderer/v8_value_converter_impl.h" |
| 119 #include "content/renderer/web_ui_extension.h" | 119 #include "content/renderer/web_ui_extension.h" |
| 120 #include "content/renderer/web_ui_extension_data.h" | 120 #include "content/renderer/web_ui_extension_data.h" |
| 121 #include "content/renderer/web_ui_mojo.h" |
| 121 #include "content/renderer/websharedworker_proxy.h" | 122 #include "content/renderer/websharedworker_proxy.h" |
| 122 #include "media/audio/audio_output_device.h" | 123 #include "media/audio/audio_output_device.h" |
| 123 #include "media/base/audio_renderer_mixer_input.h" | 124 #include "media/base/audio_renderer_mixer_input.h" |
| 124 #include "media/base/filter_collection.h" | 125 #include "media/base/filter_collection.h" |
| 125 #include "media/base/media_switches.h" | 126 #include "media/base/media_switches.h" |
| 126 #include "media/filters/audio_renderer_impl.h" | 127 #include "media/filters/audio_renderer_impl.h" |
| 127 #include "media/filters/gpu_video_accelerator_factories.h" | 128 #include "media/filters/gpu_video_accelerator_factories.h" |
| 128 #include "net/base/data_url.h" | 129 #include "net/base/data_url.h" |
| 129 #include "net/base/escape.h" | 130 #include "net/base/escape.h" |
| 130 #include "net/base/net_errors.h" | 131 #include "net/base/net_errors.h" |
| (...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 231 #if defined(ENABLE_PLUGINS) | 232 #if defined(ENABLE_PLUGINS) |
| 232 #include "content/renderer/npapi/webplugin_delegate_proxy.h" | 233 #include "content/renderer/npapi/webplugin_delegate_proxy.h" |
| 233 #include "content/renderer/pepper/pepper_plugin_instance_impl.h" | 234 #include "content/renderer/pepper/pepper_plugin_instance_impl.h" |
| 234 #include "content/renderer/pepper/pepper_plugin_registry.h" | 235 #include "content/renderer/pepper/pepper_plugin_registry.h" |
| 235 #endif | 236 #endif |
| 236 | 237 |
| 237 #if defined(ENABLE_WEBRTC) | 238 #if defined(ENABLE_WEBRTC) |
| 238 #include "content/renderer/media/rtc_peer_connection_handler.h" | 239 #include "content/renderer/media/rtc_peer_connection_handler.h" |
| 239 #endif | 240 #endif |
| 240 | 241 |
| 241 #if defined(USE_MOJO) | |
| 242 #include "content/renderer/web_ui_mojo.h" | |
| 243 #endif | |
| 244 | |
| 245 using blink::WebAXObject; | 242 using blink::WebAXObject; |
| 246 using blink::WebApplicationCacheHost; | 243 using blink::WebApplicationCacheHost; |
| 247 using blink::WebApplicationCacheHostClient; | 244 using blink::WebApplicationCacheHostClient; |
| 248 using blink::WebCString; | 245 using blink::WebCString; |
| 249 using blink::WebColor; | 246 using blink::WebColor; |
| 250 using blink::WebColorName; | 247 using blink::WebColorName; |
| 251 using blink::WebConsoleMessage; | 248 using blink::WebConsoleMessage; |
| 252 using blink::WebData; | 249 using blink::WebData; |
| 253 using blink::WebDataSource; | 250 using blink::WebDataSource; |
| 254 using blink::WebDocument; | 251 using blink::WebDocument; |
| (...skipping 3092 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 3347 WebSecurityOrigin::createFromString(WebString(params.target_origin)); | 3344 WebSecurityOrigin::createFromString(WebString(params.target_origin)); |
| 3348 } | 3345 } |
| 3349 frame->dispatchMessageEventWithOriginCheck(target_origin, msg_event); | 3346 frame->dispatchMessageEventWithOriginCheck(target_origin, msg_event); |
| 3350 } | 3347 } |
| 3351 | 3348 |
| 3352 void RenderViewImpl::OnAllowBindings(int enabled_bindings_flags) { | 3349 void RenderViewImpl::OnAllowBindings(int enabled_bindings_flags) { |
| 3353 if ((enabled_bindings_flags & BINDINGS_POLICY_WEB_UI) && | 3350 if ((enabled_bindings_flags & BINDINGS_POLICY_WEB_UI) && |
| 3354 !(enabled_bindings_ & BINDINGS_POLICY_WEB_UI)) { | 3351 !(enabled_bindings_ & BINDINGS_POLICY_WEB_UI)) { |
| 3355 // WebUIExtensionData deletes itself when we're destroyed. | 3352 // WebUIExtensionData deletes itself when we're destroyed. |
| 3356 new WebUIExtensionData(this); | 3353 new WebUIExtensionData(this); |
| 3357 #if defined(USE_MOJO) | |
| 3358 // WebUIMojo deletes itself when we're destroyed. | 3354 // WebUIMojo deletes itself when we're destroyed. |
| 3359 new WebUIMojo(this); | 3355 new WebUIMojo(this); |
| 3360 #endif | |
| 3361 } | 3356 } |
| 3362 | 3357 |
| 3363 enabled_bindings_ |= enabled_bindings_flags; | 3358 enabled_bindings_ |= enabled_bindings_flags; |
| 3364 | 3359 |
| 3365 // Keep track of the total bindings accumulated in this process. | 3360 // Keep track of the total bindings accumulated in this process. |
| 3366 RenderProcess::current()->AddBindings(enabled_bindings_flags); | 3361 RenderProcess::current()->AddBindings(enabled_bindings_flags); |
| 3367 } | 3362 } |
| 3368 | 3363 |
| 3369 void RenderViewImpl::OnDragTargetDragEnter(const DropData& drop_data, | 3364 void RenderViewImpl::OnDragTargetDragEnter(const DropData& drop_data, |
| 3370 const gfx::Point& client_point, | 3365 const gfx::Point& client_point, |
| (...skipping 1384 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4755 std::vector<gfx::Size> sizes(icon_urls[i].sizes().size()); | 4750 std::vector<gfx::Size> sizes(icon_urls[i].sizes().size()); |
| 4756 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); | 4751 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); |
| 4757 if (!url.isEmpty()) | 4752 if (!url.isEmpty()) |
| 4758 urls.push_back( | 4753 urls.push_back( |
| 4759 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); | 4754 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); |
| 4760 } | 4755 } |
| 4761 SendUpdateFaviconURL(urls); | 4756 SendUpdateFaviconURL(urls); |
| 4762 } | 4757 } |
| 4763 | 4758 |
| 4764 } // namespace content | 4759 } // namespace content |
| OLD | NEW |