| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "components/plugins/renderer/webview_plugin.h" | 5 #include "components/plugins/renderer/webview_plugin.h" |
| 6 | 6 |
| 7 #include <stddef.h> | 7 #include <stddef.h> |
| 8 | 8 |
| 9 #include "base/auto_reset.h" | 9 #include "base/auto_reset.h" |
| 10 #include "base/message_loop/message_loop.h" | 10 #include "base/message_loop/message_loop.h" |
| (...skipping 318 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 329 | 329 |
| 330 global->Set(gin::StringToV8(isolate, "plugin"), | 330 global->Set(gin::StringToV8(isolate, "plugin"), |
| 331 delegate_->GetV8Handle(isolate)); | 331 delegate_->GetV8Handle(isolate)); |
| 332 } | 332 } |
| 333 | 333 |
| 334 void WebViewPlugin::didReceiveResponse(unsigned identifier, | 334 void WebViewPlugin::didReceiveResponse(unsigned identifier, |
| 335 const WebURLResponse& response) { | 335 const WebURLResponse& response) { |
| 336 WebFrameClient::didReceiveResponse(identifier, response); | 336 WebFrameClient::didReceiveResponse(identifier, response); |
| 337 } | 337 } |
| 338 | 338 |
| 339 void WebViewPlugin::OnDestruct() { | 339 void WebViewPlugin::OnDestruct() {} |
| 340 // By default RenderViewObservers are destroyed along with the RenderView. | |
| 341 // WebViewPlugin has a custom destruction mechanism, so we disable this. | |
| 342 } | |
| 343 | 340 |
| 344 void WebViewPlugin::OnZoomLevelChanged() { | 341 void WebViewPlugin::OnZoomLevelChanged() { |
| 345 if (container_) { | 342 if (container_) { |
| 346 web_view_->setZoomLevel( | 343 web_view_->setZoomLevel( |
| 347 blink::WebView::zoomFactorToZoomLevel(container_->pageZoomFactor())); | 344 blink::WebView::zoomFactorToZoomLevel(container_->pageZoomFactor())); |
| 348 } | 345 } |
| 349 } | 346 } |
| OLD | NEW |