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 191 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
202 #include "ui/gfx/native_widget_types.h" | 202 #include "ui/gfx/native_widget_types.h" |
203 #include "ui/gfx/point.h" | 203 #include "ui/gfx/point.h" |
204 #include "ui/gfx/rect.h" | 204 #include "ui/gfx/rect.h" |
205 #include "ui/gfx/rect_conversions.h" | 205 #include "ui/gfx/rect_conversions.h" |
206 #include "ui/gfx/size_conversions.h" | 206 #include "ui/gfx/size_conversions.h" |
207 #include "ui/shell_dialogs/selected_file_info.h" | 207 #include "ui/shell_dialogs/selected_file_info.h" |
208 #include "v8/include/v8.h" | 208 #include "v8/include/v8.h" |
209 #include "webkit/common/dom_storage/dom_storage_types.h" | 209 #include "webkit/common/dom_storage/dom_storage_types.h" |
210 #include "webkit/glue/webkit_glue.h" | 210 #include "webkit/glue/webkit_glue.h" |
211 #include "webkit/glue/weburlresponse_extradata_impl.h" | 211 #include "webkit/glue/weburlresponse_extradata_impl.h" |
212 #include "webkit/plugins/npapi/plugin_utils.h" | |
213 #include "webkit/renderer/appcache/web_application_cache_host_impl.h" | 212 #include "webkit/renderer/appcache/web_application_cache_host_impl.h" |
214 #include "webkit/renderer/webpreferences_renderer.h" | 213 #include "webkit/renderer/webpreferences_renderer.h" |
215 | 214 |
216 #if defined(OS_ANDROID) | 215 #if defined(OS_ANDROID) |
217 #include <cpu-features.h> | 216 #include <cpu-features.h> |
218 | 217 |
219 #include "content/common/android/device_telephony_info.h" | 218 #include "content/common/android/device_telephony_info.h" |
220 #include "content/common/gpu/client/context_provider_command_buffer.h" | 219 #include "content/common/gpu/client/context_provider_command_buffer.h" |
221 #include "content/renderer/android/address_detector.h" | 220 #include "content/renderer/android/address_detector.h" |
222 #include "content/renderer/android/content_detector.h" | 221 #include "content/renderer/android/content_detector.h" |
(...skipping 4461 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4684 WebKit::WebPlugin* RenderViewImpl::CreatePlugin( | 4683 WebKit::WebPlugin* RenderViewImpl::CreatePlugin( |
4685 WebKit::WebFrame* frame, | 4684 WebKit::WebFrame* frame, |
4686 const webkit::WebPluginInfo& info, | 4685 const webkit::WebPluginInfo& info, |
4687 const WebKit::WebPluginParams& params) { | 4686 const WebKit::WebPluginParams& params) { |
4688 WebKit::WebPlugin* pepper_webplugin = | 4687 WebKit::WebPlugin* pepper_webplugin = |
4689 pepper_helper_->CreatePepperWebPlugin(info, params); | 4688 pepper_helper_->CreatePepperWebPlugin(info, params); |
4690 | 4689 |
4691 if (pepper_webplugin) | 4690 if (pepper_webplugin) |
4692 return pepper_webplugin; | 4691 return pepper_webplugin; |
4693 | 4692 |
4694 if (!webkit::npapi::NPAPIPluginsSupported()) | |
4695 return NULL; | |
4696 | |
4697 return new WebPluginImpl(frame, params, info.path, AsWeakPtr()); | 4693 return new WebPluginImpl(frame, params, info.path, AsWeakPtr()); |
4698 } | 4694 } |
4699 | 4695 |
4700 void RenderViewImpl::EvaluateScript(const string16& frame_xpath, | 4696 void RenderViewImpl::EvaluateScript(const string16& frame_xpath, |
4701 const string16& jscript, | 4697 const string16& jscript, |
4702 int id, | 4698 int id, |
4703 bool notify_result) { | 4699 bool notify_result) { |
4704 v8::HandleScope handle_scope; | 4700 v8::HandleScope handle_scope; |
4705 v8::Handle<v8::Value> result; | 4701 v8::Handle<v8::Value> result; |
4706 WebFrame* web_frame = GetChildFrame(frame_xpath); | 4702 WebFrame* web_frame = GetChildFrame(frame_xpath); |
(...skipping 2098 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
6805 WebURL url = icon_urls[i].iconURL(); | 6801 WebURL url = icon_urls[i].iconURL(); |
6806 if (!url.isEmpty()) | 6802 if (!url.isEmpty()) |
6807 urls.push_back(FaviconURL(url, | 6803 urls.push_back(FaviconURL(url, |
6808 ToFaviconType(icon_urls[i].iconType()))); | 6804 ToFaviconType(icon_urls[i].iconType()))); |
6809 } | 6805 } |
6810 SendUpdateFaviconURL(urls); | 6806 SendUpdateFaviconURL(urls); |
6811 } | 6807 } |
6812 | 6808 |
6813 | 6809 |
6814 } // namespace content | 6810 } // namespace content |
OLD | NEW |