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/browser/renderer_host/render_widget_host_view_base.h" | 5 #include "content/browser/renderer_host/render_widget_host_view_base.h" |
6 | 6 |
7 #include "base/logging.h" | 7 #include "base/logging.h" |
8 #include "build/build_config.h" | 8 #include "build/build_config.h" |
9 #include "content/browser/accessibility/browser_accessibility_manager.h" | 9 #include "content/browser/accessibility/browser_accessibility_manager.h" |
10 #include "content/browser/gpu/gpu_data_manager_impl.h" | 10 #include "content/browser/gpu/gpu_data_manager_impl.h" |
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
289 return true; | 289 return true; |
290 } | 290 } |
291 | 291 |
292 void RenderWidgetHostViewBase::DidUnregisterFromTextInputManager( | 292 void RenderWidgetHostViewBase::DidUnregisterFromTextInputManager( |
293 TextInputManager* text_input_manager) { | 293 TextInputManager* text_input_manager) { |
294 DCHECK(text_input_manager && text_input_manager_ == text_input_manager); | 294 DCHECK(text_input_manager && text_input_manager_ == text_input_manager); |
295 | 295 |
296 text_input_manager_ = nullptr; | 296 text_input_manager_ = nullptr; |
297 } | 297 } |
298 | 298 |
| 299 void RenderWidgetHostViewBase::UpdatePageScaleFactor(float page_scale) { |
| 300 RenderWidgetHostImpl* host = |
| 301 RenderWidgetHostImpl::From(GetRenderWidgetHost()); |
| 302 |
| 303 if (host && host->delegate()) |
| 304 host->delegate()->UpdatePageScaleFactor(page_scale); |
| 305 } |
| 306 |
299 base::WeakPtr<RenderWidgetHostViewBase> RenderWidgetHostViewBase::GetWeakPtr() { | 307 base::WeakPtr<RenderWidgetHostViewBase> RenderWidgetHostViewBase::GetWeakPtr() { |
300 return weak_factory_.GetWeakPtr(); | 308 return weak_factory_.GetWeakPtr(); |
301 } | 309 } |
302 | 310 |
303 std::unique_ptr<SyntheticGestureTarget> | 311 std::unique_ptr<SyntheticGestureTarget> |
304 RenderWidgetHostViewBase::CreateSyntheticGestureTarget() { | 312 RenderWidgetHostViewBase::CreateSyntheticGestureTarget() { |
305 RenderWidgetHostImpl* host = | 313 RenderWidgetHostImpl* host = |
306 RenderWidgetHostImpl::From(GetRenderWidgetHost()); | 314 RenderWidgetHostImpl::From(GetRenderWidgetHost()); |
307 return std::unique_ptr<SyntheticGestureTarget>( | 315 return std::unique_ptr<SyntheticGestureTarget>( |
308 new SyntheticGestureTargetBase(host)); | 316 new SyntheticGestureTargetBase(host)); |
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
520 | 528 |
521 bool RenderWidgetHostViewBase::IsChildFrameForTesting() const { | 529 bool RenderWidgetHostViewBase::IsChildFrameForTesting() const { |
522 return false; | 530 return false; |
523 } | 531 } |
524 | 532 |
525 cc::SurfaceId RenderWidgetHostViewBase::SurfaceIdForTesting() const { | 533 cc::SurfaceId RenderWidgetHostViewBase::SurfaceIdForTesting() const { |
526 return cc::SurfaceId(); | 534 return cc::SurfaceId(); |
527 } | 535 } |
528 | 536 |
529 } // namespace content | 537 } // namespace content |
OLD | NEW |