Chromium Code Reviews| 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 10 matching lines...) Expand all Loading... | |
| 21 #include "base/metrics/field_trial.h" | 21 #include "base/metrics/field_trial.h" |
| 22 #include "base/metrics/histogram.h" | 22 #include "base/metrics/histogram.h" |
| 23 #include "base/process/kill.h" | 23 #include "base/process/kill.h" |
| 24 #include "base/process/process.h" | 24 #include "base/process/process.h" |
| 25 #include "base/strings/string_number_conversions.h" | 25 #include "base/strings/string_number_conversions.h" |
| 26 #include "base/strings/string_piece.h" | 26 #include "base/strings/string_piece.h" |
| 27 #include "base/strings/string_split.h" | 27 #include "base/strings/string_split.h" |
| 28 #include "base/strings/string_util.h" | 28 #include "base/strings/string_util.h" |
| 29 #include "base/strings/sys_string_conversions.h" | 29 #include "base/strings/sys_string_conversions.h" |
| 30 #include "base/strings/utf_string_conversions.h" | 30 #include "base/strings/utf_string_conversions.h" |
| 31 #include "base/synchronization/waitable_event.h" | |
| 31 #include "base/time/time.h" | 32 #include "base/time/time.h" |
| 32 #include "base/trace_event/trace_event.h" | 33 #include "base/trace_event/trace_event.h" |
| 33 #include "content/child/appcache/appcache_dispatcher.h" | 34 #include "content/child/appcache/appcache_dispatcher.h" |
| 34 #include "content/child/appcache/web_application_cache_host_impl.h" | 35 #include "content/child/appcache/web_application_cache_host_impl.h" |
| 35 #include "content/child/child_shared_bitmap_manager.h" | 36 #include "content/child/child_shared_bitmap_manager.h" |
| 36 #include "content/child/npapi/webplugin_delegate_impl.h" | 37 #include "content/child/npapi/webplugin_delegate_impl.h" |
| 37 #include "content/child/request_extra_data.h" | 38 #include "content/child/request_extra_data.h" |
| 38 #include "content/child/v8_value_converter_impl.h" | 39 #include "content/child/v8_value_converter_impl.h" |
| 39 #include "content/child/webmessageportchannel_impl.h" | 40 #include "content/child/webmessageportchannel_impl.h" |
| 40 #include "content/common/content_constants_internal.h" | 41 #include "content/common/content_constants_internal.h" |
| (...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 206 #endif | 207 #endif |
| 207 | 208 |
| 208 #if defined(ENABLE_WEBRTC) | 209 #if defined(ENABLE_WEBRTC) |
| 209 #include "content/renderer/media/rtc_peer_connection_handler.h" | 210 #include "content/renderer/media/rtc_peer_connection_handler.h" |
| 210 #include "content/renderer/media/webrtc/peer_connection_dependency_factory.h" | 211 #include "content/renderer/media/webrtc/peer_connection_dependency_factory.h" |
| 211 #endif | 212 #endif |
| 212 | 213 |
| 213 #if defined(MOJO_SHELL_CLIENT) | 214 #if defined(MOJO_SHELL_CLIENT) |
| 214 #include "content/public/common/mojo_shell_connection.h" | 215 #include "content/public/common/mojo_shell_connection.h" |
| 215 #include "content/renderer/render_widget_mus_connection.h" | 216 #include "content/renderer/render_widget_mus_connection.h" |
| 217 #include "mojo/application/public/cpp/application_impl.h" | |
| 216 #endif | 218 #endif |
| 217 | 219 |
| 218 using blink::WebAXObject; | 220 using blink::WebAXObject; |
| 219 using blink::WebApplicationCacheHost; | 221 using blink::WebApplicationCacheHost; |
|
sadrul
2015/12/02 18:20:57
The new includes probably aren't necessary?
Fady Samuel
2015/12/02 21:30:28
Reverted.
| |
| 220 using blink::WebApplicationCacheHostClient; | 222 using blink::WebApplicationCacheHostClient; |
| 221 using blink::WebCString; | 223 using blink::WebCString; |
| 222 using blink::WebColor; | 224 using blink::WebColor; |
| 223 using blink::WebConsoleMessage; | 225 using blink::WebConsoleMessage; |
| 224 using blink::WebData; | 226 using blink::WebData; |
| 225 using blink::WebDataSource; | 227 using blink::WebDataSource; |
| 226 using blink::WebDocument; | 228 using blink::WebDocument; |
| 227 using blink::WebDragData; | 229 using blink::WebDragData; |
| 228 using blink::WebDragOperation; | 230 using blink::WebDragOperation; |
| 229 using blink::WebDragOperationsMask; | 231 using blink::WebDragOperationsMask; |
| (...skipping 1483 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 1713 void RenderViewImpl::AttachWebFrameWidget(blink::WebWidget* frame_widget) { | 1715 void RenderViewImpl::AttachWebFrameWidget(blink::WebWidget* frame_widget) { |
| 1714 // The previous WebFrameWidget must already be detached by CloseForFrame(). | 1716 // The previous WebFrameWidget must already be detached by CloseForFrame(). |
| 1715 DCHECK(!frame_widget_); | 1717 DCHECK(!frame_widget_); |
| 1716 frame_widget_ = frame_widget; | 1718 frame_widget_ = frame_widget; |
| 1717 } | 1719 } |
| 1718 | 1720 |
| 1719 scoped_ptr<cc::OutputSurface> RenderViewImpl::CreateOutputSurface( | 1721 scoped_ptr<cc::OutputSurface> RenderViewImpl::CreateOutputSurface( |
| 1720 bool fallback) { | 1722 bool fallback) { |
| 1721 if (MojoShellConnection::Get()->GetApplication()) { | 1723 if (MojoShellConnection::Get()->GetApplication()) { |
| 1722 RenderWidgetMusConnection* connection = | 1724 RenderWidgetMusConnection* connection = |
| 1723 RenderWidgetMusConnection::Get(routing_id()); | 1725 RenderWidgetMusConnection::GetOrCreate(routing_id()); |
| 1724 return connection->CreateOutputSurface(); | 1726 return connection->CreateOutputSurface(); |
| 1725 } | 1727 } |
| 1726 return RenderWidget::CreateOutputSurface(fallback); | 1728 return RenderWidget::CreateOutputSurface(fallback); |
| 1727 } | 1729 } |
| 1728 | 1730 |
| 1729 void RenderViewImpl::SetZoomLevel(double zoom_level) { | 1731 void RenderViewImpl::SetZoomLevel(double zoom_level) { |
| 1730 webview()->setZoomLevel(zoom_level); | 1732 webview()->setZoomLevel(zoom_level); |
| 1731 FOR_EACH_OBSERVER(RenderViewObserver, observers_, OnZoomLevelChanged()); | 1733 FOR_EACH_OBSERVER(RenderViewObserver, observers_, OnZoomLevelChanged()); |
| 1732 } | 1734 } |
| 1733 | 1735 |
| (...skipping 2001 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 3735 if (IsUseZoomForDSFEnabled()) { | 3737 if (IsUseZoomForDSFEnabled()) { |
| 3736 compositor_->SetPaintedDeviceScaleFactor(device_scale_factor_); | 3738 compositor_->SetPaintedDeviceScaleFactor(device_scale_factor_); |
| 3737 webview()->setZoomFactorForDeviceScaleFactor( | 3739 webview()->setZoomFactorForDeviceScaleFactor( |
| 3738 device_scale_factor_); | 3740 device_scale_factor_); |
| 3739 } else { | 3741 } else { |
| 3740 webview()->setDeviceScaleFactor(device_scale_factor_); | 3742 webview()->setDeviceScaleFactor(device_scale_factor_); |
| 3741 } | 3743 } |
| 3742 } | 3744 } |
| 3743 | 3745 |
| 3744 } // namespace content | 3746 } // namespace content |
| OLD | NEW |