| 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 207 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 218 | 218 |
| 219 #if defined(OS_ANDROID) | 219 #if defined(OS_ANDROID) |
| 220 #include <cpu-features.h> | 220 #include <cpu-features.h> |
| 221 | 221 |
| 222 #include "content/common/android/device_telephony_info.h" | 222 #include "content/common/android/device_telephony_info.h" |
| 223 #include "content/common/gpu/client/context_provider_command_buffer.h" | 223 #include "content/common/gpu/client/context_provider_command_buffer.h" |
| 224 #include "content/renderer/android/address_detector.h" | 224 #include "content/renderer/android/address_detector.h" |
| 225 #include "content/renderer/android/content_detector.h" | 225 #include "content/renderer/android/content_detector.h" |
| 226 #include "content/renderer/android/email_detector.h" | 226 #include "content/renderer/android/email_detector.h" |
| 227 #include "content/renderer/android/phone_number_detector.h" | 227 #include "content/renderer/android/phone_number_detector.h" |
| 228 #include "content/renderer/media/android/webmediaplayer_android.h" |
| 229 #include "content/renderer/media/android/webmediaplayer_manager_android.h" |
| 228 #include "content/renderer/media/stream_texture_factory_impl_android.h" | 230 #include "content/renderer/media/stream_texture_factory_impl_android.h" |
| 229 #include "content/renderer/media/webmediaplayer_proxy_impl_android.h" | 231 #include "content/renderer/media/webmediaplayer_proxy_impl_android.h" |
| 230 #include "third_party/WebKit/public/web/WebHitTestResult.h" | 232 #include "third_party/WebKit/public/web/WebHitTestResult.h" |
| 231 #include "third_party/WebKit/public/platform/WebFloatPoint.h" | 233 #include "third_party/WebKit/public/platform/WebFloatPoint.h" |
| 232 #include "third_party/WebKit/public/platform/WebFloatRect.h" | 234 #include "third_party/WebKit/public/platform/WebFloatRect.h" |
| 233 #include "ui/gfx/rect_f.h" | 235 #include "ui/gfx/rect_f.h" |
| 234 #include "webkit/renderer/media/android/webmediaplayer_android.h" | |
| 235 #include "webkit/renderer/media/android/webmediaplayer_manager_android.h" | |
| 236 | 236 |
| 237 #if defined(GOOGLE_TV) | 237 #if defined(GOOGLE_TV) |
| 238 #include "content/renderer/media/rtc_video_decoder_bridge_tv.h" | 238 #include "content/renderer/media/rtc_video_decoder_bridge_tv.h" |
| 239 #include "content/renderer/media/rtc_video_decoder_factory_tv.h" | 239 #include "content/renderer/media/rtc_video_decoder_factory_tv.h" |
| 240 #endif | 240 #endif |
| 241 | 241 |
| 242 #elif defined(OS_WIN) | 242 #elif defined(OS_WIN) |
| 243 // TODO(port): these files are currently Windows only because they concern: | 243 // TODO(port): these files are currently Windows only because they concern: |
| 244 // * theming | 244 // * theming |
| 245 #include "ui/native_theme/native_theme_win.h" | 245 #include "ui/native_theme/native_theme_win.h" |
| (...skipping 657 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 903 if (!media_stream_dispatcher_) | 903 if (!media_stream_dispatcher_) |
| 904 media_stream_dispatcher_ = new MediaStreamDispatcher(this); | 904 media_stream_dispatcher_ = new MediaStreamDispatcher(this); |
| 905 #endif | 905 #endif |
| 906 | 906 |
| 907 new MHTMLGenerator(this); | 907 new MHTMLGenerator(this); |
| 908 #if defined(OS_MACOSX) | 908 #if defined(OS_MACOSX) |
| 909 new TextInputClientObserver(this); | 909 new TextInputClientObserver(this); |
| 910 #endif // defined(OS_MACOSX) | 910 #endif // defined(OS_MACOSX) |
| 911 | 911 |
| 912 #if defined(OS_ANDROID) | 912 #if defined(OS_ANDROID) |
| 913 media_player_manager_.reset( | 913 media_player_manager_.reset(new WebMediaPlayerManagerAndroid()); |
| 914 new webkit_media::WebMediaPlayerManagerAndroid()); | |
| 915 #endif | 914 #endif |
| 916 | 915 |
| 917 // The next group of objects all implement RenderViewObserver, so are deleted | 916 // The next group of objects all implement RenderViewObserver, so are deleted |
| 918 // along with the RenderView automatically. | 917 // along with the RenderView automatically. |
| 919 devtools_agent_ = new DevToolsAgent(this); | 918 devtools_agent_ = new DevToolsAgent(this); |
| 920 mouse_lock_dispatcher_ = new RenderViewMouseLockDispatcher(this); | 919 mouse_lock_dispatcher_ = new RenderViewMouseLockDispatcher(this); |
| 921 | 920 |
| 922 new ImageLoadingHelper(this); | 921 new ImageLoadingHelper(this); |
| 923 | 922 |
| 924 // Create renderer_accessibility_ if needed. | 923 // Create renderer_accessibility_ if needed. |
| (...skipping 1940 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2865 RenderThreadImpl::current()->OffscreenContextProviderForMainThread(); | 2864 RenderThreadImpl::current()->OffscreenContextProviderForMainThread(); |
| 2866 if (!context_provider.get()) { | 2865 if (!context_provider.get()) { |
| 2867 LOG(ERROR) << "Failed to get context3d for media player"; | 2866 LOG(ERROR) << "Failed to get context3d for media player"; |
| 2868 return NULL; | 2867 return NULL; |
| 2869 } | 2868 } |
| 2870 | 2869 |
| 2871 if (!media_player_proxy_) { | 2870 if (!media_player_proxy_) { |
| 2872 media_player_proxy_ = new WebMediaPlayerProxyImplAndroid( | 2871 media_player_proxy_ = new WebMediaPlayerProxyImplAndroid( |
| 2873 this, media_player_manager_.get()); | 2872 this, media_player_manager_.get()); |
| 2874 } | 2873 } |
| 2875 scoped_ptr<webkit_media::WebMediaPlayerAndroid> web_media_player_android( | 2874 scoped_ptr<WebMediaPlayerAndroid> web_media_player_android( |
| 2876 new webkit_media::WebMediaPlayerAndroid( | 2875 new WebMediaPlayerAndroid( |
| 2877 frame, | 2876 frame, |
| 2878 client, | 2877 client, |
| 2879 AsWeakPtr(), | 2878 AsWeakPtr(), |
| 2880 media_player_manager_.get(), | 2879 media_player_manager_.get(), |
| 2881 media_player_proxy_, | 2880 media_player_proxy_, |
| 2882 new StreamTextureFactoryImpl( | 2881 new StreamTextureFactoryImpl( |
| 2883 context_provider->Context3d(), gpu_channel_host, routing_id_), | 2882 context_provider->Context3d(), gpu_channel_host, routing_id_), |
| 2884 new RenderMediaLog())); | 2883 new RenderMediaLog())); |
| 2885 #if defined(ENABLE_WEBRTC) && defined(GOOGLE_TV) | 2884 #if defined(ENABLE_WEBRTC) && defined(GOOGLE_TV) |
| 2886 if (MediaStreamImpl::CheckMediaStream(url)) { | 2885 if (MediaStreamImpl::CheckMediaStream(url)) { |
| (...skipping 3880 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6767 WebURL url = icon_urls[i].iconURL(); | 6766 WebURL url = icon_urls[i].iconURL(); |
| 6768 if (!url.isEmpty()) | 6767 if (!url.isEmpty()) |
| 6769 urls.push_back(FaviconURL(url, | 6768 urls.push_back(FaviconURL(url, |
| 6770 ToFaviconType(icon_urls[i].iconType()))); | 6769 ToFaviconType(icon_urls[i].iconType()))); |
| 6771 } | 6770 } |
| 6772 SendUpdateFaviconURL(urls); | 6771 SendUpdateFaviconURL(urls); |
| 6773 } | 6772 } |
| 6774 | 6773 |
| 6775 | 6774 |
| 6776 } // namespace content | 6775 } // namespace content |
| OLD | NEW |