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/bind.h" | 10 #include "base/bind.h" |
(...skipping 196 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
207 #include "webkit/media/webmediaplayer_impl.h" | 207 #include "webkit/media/webmediaplayer_impl.h" |
208 #include "webkit/media/webmediaplayer_ms.h" | 208 #include "webkit/media/webmediaplayer_ms.h" |
209 #include "webkit/media/webmediaplayer_params.h" | 209 #include "webkit/media/webmediaplayer_params.h" |
210 #include "webkit/plugins/npapi/plugin_list.h" | 210 #include "webkit/plugins/npapi/plugin_list.h" |
211 #include "webkit/plugins/npapi/plugin_utils.h" | 211 #include "webkit/plugins/npapi/plugin_utils.h" |
212 #include "webkit/plugins/npapi/webplugin_delegate.h" | 212 #include "webkit/plugins/npapi/webplugin_delegate.h" |
213 #include "webkit/plugins/npapi/webplugin_delegate_impl.h" | 213 #include "webkit/plugins/npapi/webplugin_delegate_impl.h" |
214 #include "webkit/plugins/npapi/webplugin_impl.h" | 214 #include "webkit/plugins/npapi/webplugin_impl.h" |
215 | 215 |
216 #if defined(OS_ANDROID) | 216 #if defined(OS_ANDROID) |
217 #include "content/common/android/device_info.h" | 217 #include "content/common/android/device_telephony_info.h" |
218 #include "content/renderer/android/address_detector.h" | 218 #include "content/renderer/android/address_detector.h" |
219 #include "content/renderer/android/content_detector.h" | 219 #include "content/renderer/android/content_detector.h" |
220 #include "content/renderer/android/email_detector.h" | 220 #include "content/renderer/android/email_detector.h" |
221 #include "content/renderer/android/phone_number_detector.h" | 221 #include "content/renderer/android/phone_number_detector.h" |
222 #include "content/renderer/media/stream_texture_factory_impl_android.h" | 222 #include "content/renderer/media/stream_texture_factory_impl_android.h" |
223 #include "content/renderer/media/webmediaplayer_proxy_impl_android.h" | 223 #include "content/renderer/media/webmediaplayer_proxy_impl_android.h" |
224 #include "third_party/WebKit/Source/Platform/chromium/public/WebFloatPoint.h" | 224 #include "third_party/WebKit/Source/Platform/chromium/public/WebFloatPoint.h" |
225 #include "third_party/WebKit/Source/Platform/chromium/public/WebFloatRect.h" | 225 #include "third_party/WebKit/Source/Platform/chromium/public/WebFloatRect.h" |
226 #include "third_party/WebKit/Source/WebKit/chromium/public/WebHitTestResult.h" | 226 #include "third_party/WebKit/Source/WebKit/chromium/public/WebHitTestResult.h" |
227 #include "ui/gfx/rect_f.h" | 227 #include "ui/gfx/rect_f.h" |
(...skipping 430 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
658 #else | 658 #else |
659 notification_provider_ = NULL; | 659 notification_provider_ = NULL; |
660 #endif | 660 #endif |
661 | 661 |
662 webwidget_ = WebView::create(this); | 662 webwidget_ = WebView::create(this); |
663 webwidget_mouse_lock_target_.reset(new WebWidgetLockTarget(webwidget_)); | 663 webwidget_mouse_lock_target_.reset(new WebWidgetLockTarget(webwidget_)); |
664 | 664 |
665 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); | 665 const CommandLine& command_line = *CommandLine::ForCurrentProcess(); |
666 | 666 |
667 #if defined(OS_ANDROID) | 667 #if defined(OS_ANDROID) |
668 scoped_ptr<DeviceInfo> device_info(new DeviceInfo()); | 668 content::DeviceTelephonyInfo device_info; |
669 | 669 |
670 const std::string region_code = | 670 const std::string region_code = |
671 command_line.HasSwitch(switches::kNetworkCountryIso) | 671 command_line.HasSwitch(switches::kNetworkCountryIso) |
672 ? command_line.GetSwitchValueASCII(switches::kNetworkCountryIso) | 672 ? command_line.GetSwitchValueASCII(switches::kNetworkCountryIso) |
673 : device_info->GetNetworkCountryIso(); | 673 : device_info.GetNetworkCountryIso(); |
674 content_detectors_.push_back(linked_ptr<ContentDetector>( | 674 content_detectors_.push_back(linked_ptr<ContentDetector>( |
675 new AddressDetector())); | 675 new AddressDetector())); |
676 content_detectors_.push_back(linked_ptr<ContentDetector>( | 676 content_detectors_.push_back(linked_ptr<ContentDetector>( |
677 new PhoneNumberDetector(region_code))); | 677 new PhoneNumberDetector(region_code))); |
678 content_detectors_.push_back(linked_ptr<ContentDetector>( | 678 content_detectors_.push_back(linked_ptr<ContentDetector>( |
679 new EmailDetector())); | 679 new EmailDetector())); |
680 #endif | 680 #endif |
681 | 681 |
682 if (params->counter) { | 682 if (params->counter) { |
683 shared_popup_counter_ = params->counter; | 683 shared_popup_counter_ = params->counter; |
(...skipping 5911 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6595 } | 6595 } |
6596 #endif | 6596 #endif |
6597 | 6597 |
6598 void RenderViewImpl::OnReleaseDisambiguationPopupDIB( | 6598 void RenderViewImpl::OnReleaseDisambiguationPopupDIB( |
6599 TransportDIB::Handle dib_handle) { | 6599 TransportDIB::Handle dib_handle) { |
6600 TransportDIB* dib = TransportDIB::CreateWithHandle(dib_handle); | 6600 TransportDIB* dib = TransportDIB::CreateWithHandle(dib_handle); |
6601 RenderProcess::current()->ReleaseTransportDIB(dib); | 6601 RenderProcess::current()->ReleaseTransportDIB(dib); |
6602 } | 6602 } |
6603 | 6603 |
6604 } // namespace content | 6604 } // namespace content |
OLD | NEW |