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 82 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
93 #include "content/renderer/media/media_stream_impl.h" | 93 #include "content/renderer/media/media_stream_impl.h" |
94 #include "content/renderer/media/midi_dispatcher.h" | 94 #include "content/renderer/media/midi_dispatcher.h" |
95 #include "content/renderer/media/render_media_log.h" | 95 #include "content/renderer/media/render_media_log.h" |
96 #include "content/renderer/media/video_capture_impl_manager.h" | 96 #include "content/renderer/media/video_capture_impl_manager.h" |
97 #include "content/renderer/media/webmediaplayer_impl.h" | 97 #include "content/renderer/media/webmediaplayer_impl.h" |
98 #include "content/renderer/media/webmediaplayer_ms.h" | 98 #include "content/renderer/media/webmediaplayer_ms.h" |
99 #include "content/renderer/media/webmediaplayer_params.h" | 99 #include "content/renderer/media/webmediaplayer_params.h" |
100 #include "content/renderer/memory_benchmarking_extension.h" | 100 #include "content/renderer/memory_benchmarking_extension.h" |
101 #include "content/renderer/mhtml_generator.h" | 101 #include "content/renderer/mhtml_generator.h" |
102 #include "content/renderer/notification_provider.h" | 102 #include "content/renderer/notification_provider.h" |
| 103 #include "content/renderer/push_messaging_dispatcher.h" |
103 #include "content/renderer/render_frame_impl.h" | 104 #include "content/renderer/render_frame_impl.h" |
104 #include "content/renderer/render_process.h" | 105 #include "content/renderer/render_process.h" |
105 #include "content/renderer/render_thread_impl.h" | 106 #include "content/renderer/render_thread_impl.h" |
106 #include "content/renderer/render_view_impl_params.h" | 107 #include "content/renderer/render_view_impl_params.h" |
107 #include "content/renderer/render_view_mouse_lock_dispatcher.h" | 108 #include "content/renderer/render_view_mouse_lock_dispatcher.h" |
108 #include "content/renderer/render_widget_fullscreen_pepper.h" | 109 #include "content/renderer/render_widget_fullscreen_pepper.h" |
109 #include "content/renderer/renderer_webapplicationcachehost_impl.h" | 110 #include "content/renderer/renderer_webapplicationcachehost_impl.h" |
110 #include "content/renderer/renderer_webcolorchooser_impl.h" | 111 #include "content/renderer/renderer_webcolorchooser_impl.h" |
111 #include "content/renderer/resizing_mode_selector.h" | 112 #include "content/renderer/resizing_mode_selector.h" |
112 #include "content/renderer/savable_resources.h" | 113 #include "content/renderer/savable_resources.h" |
(...skipping 546 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
659 target_url_status_(TARGET_NONE), | 660 target_url_status_(TARGET_NONE), |
660 #if defined(OS_ANDROID) | 661 #if defined(OS_ANDROID) |
661 top_controls_constraints_(cc::BOTH), | 662 top_controls_constraints_(cc::BOTH), |
662 #endif | 663 #endif |
663 cached_is_main_frame_pinned_to_left_(false), | 664 cached_is_main_frame_pinned_to_left_(false), |
664 cached_is_main_frame_pinned_to_right_(false), | 665 cached_is_main_frame_pinned_to_right_(false), |
665 cached_has_main_frame_horizontal_scrollbar_(false), | 666 cached_has_main_frame_horizontal_scrollbar_(false), |
666 cached_has_main_frame_vertical_scrollbar_(false), | 667 cached_has_main_frame_vertical_scrollbar_(false), |
667 has_scrolled_focused_editable_node_into_rect_(false), | 668 has_scrolled_focused_editable_node_into_rect_(false), |
668 notification_provider_(NULL), | 669 notification_provider_(NULL), |
| 670 push_messaging_dispatcher_(NULL), |
669 geolocation_dispatcher_(NULL), | 671 geolocation_dispatcher_(NULL), |
670 input_tag_speech_dispatcher_(NULL), | 672 input_tag_speech_dispatcher_(NULL), |
671 speech_recognition_dispatcher_(NULL), | 673 speech_recognition_dispatcher_(NULL), |
672 media_stream_dispatcher_(NULL), | 674 media_stream_dispatcher_(NULL), |
673 browser_plugin_manager_(NULL), | 675 browser_plugin_manager_(NULL), |
674 media_stream_client_(NULL), | 676 media_stream_client_(NULL), |
675 web_user_media_client_(NULL), | 677 web_user_media_client_(NULL), |
676 midi_dispatcher_(NULL), | 678 midi_dispatcher_(NULL), |
677 devtools_agent_(NULL), | 679 devtools_agent_(NULL), |
678 accessibility_mode_(AccessibilityModeOff), | 680 accessibility_mode_(AccessibilityModeOff), |
(...skipping 3708 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4387 | 4389 |
4388 return web_user_media_client_; | 4390 return web_user_media_client_; |
4389 } | 4391 } |
4390 | 4392 |
4391 blink::WebMIDIClient* RenderViewImpl::webMIDIClient() { | 4393 blink::WebMIDIClient* RenderViewImpl::webMIDIClient() { |
4392 if (!midi_dispatcher_) | 4394 if (!midi_dispatcher_) |
4393 midi_dispatcher_ = new MidiDispatcher(this); | 4395 midi_dispatcher_ = new MidiDispatcher(this); |
4394 return midi_dispatcher_; | 4396 return midi_dispatcher_; |
4395 } | 4397 } |
4396 | 4398 |
| 4399 blink::WebPushClient* RenderViewImpl::webPushClient() { |
| 4400 if (!push_messaging_dispatcher_) |
| 4401 push_messaging_dispatcher_ = new PushMessagingDispatcher(this); |
| 4402 return push_messaging_dispatcher_; |
| 4403 } |
| 4404 |
4397 void RenderViewImpl::draggableRegionsChanged() { | 4405 void RenderViewImpl::draggableRegionsChanged() { |
4398 FOR_EACH_OBSERVER( | 4406 FOR_EACH_OBSERVER( |
4399 RenderViewObserver, | 4407 RenderViewObserver, |
4400 observers_, | 4408 observers_, |
4401 DraggableRegionsChanged(webview()->mainFrame())); | 4409 DraggableRegionsChanged(webview()->mainFrame())); |
4402 } | 4410 } |
4403 | 4411 |
4404 WebMediaPlayer* RenderViewImpl::CreateWebMediaPlayerForMediaStream( | 4412 WebMediaPlayer* RenderViewImpl::CreateWebMediaPlayerForMediaStream( |
4405 WebFrame* frame, | 4413 WebFrame* frame, |
4406 const blink::WebURL& url, | 4414 const blink::WebURL& url, |
(...skipping 343 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4750 std::vector<gfx::Size> sizes(icon_urls[i].sizes().size()); | 4758 std::vector<gfx::Size> sizes(icon_urls[i].sizes().size()); |
4751 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); | 4759 ConvertToFaviconSizes(icon_urls[i].sizes(), &sizes); |
4752 if (!url.isEmpty()) | 4760 if (!url.isEmpty()) |
4753 urls.push_back( | 4761 urls.push_back( |
4754 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); | 4762 FaviconURL(url, ToFaviconType(icon_urls[i].iconType()), sizes)); |
4755 } | 4763 } |
4756 SendUpdateFaviconURL(urls); | 4764 SendUpdateFaviconURL(urls); |
4757 } | 4765 } |
4758 | 4766 |
4759 } // namespace content | 4767 } // namespace content |
OLD | NEW |