Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(408)

Side by Side Diff: content/browser/renderer_host/render_widget_host_view_base.cc

Issue 1713473002: Make TestRenderWidgetHostView::Show/Hide call through to RWHI (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@crash
Patch Set: Update web_contents_impl_unittest.cc Created 4 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
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 383 matching lines...) Expand 10 before | Expand all | Expand 10 after
394 394
395 void RenderWidgetHostViewBase::SetBackgroundColorToDefault() { 395 void RenderWidgetHostViewBase::SetBackgroundColorToDefault() {
396 SetBackgroundColor(SK_ColorWHITE); 396 SetBackgroundColor(SK_ColorWHITE);
397 } 397 }
398 398
399 bool RenderWidgetHostViewBase::GetBackgroundOpaque() { 399 bool RenderWidgetHostViewBase::GetBackgroundOpaque() {
400 return SkColorGetA(background_color_) == SK_AlphaOPAQUE; 400 return SkColorGetA(background_color_) == SK_AlphaOPAQUE;
401 } 401 }
402 402
403 gfx::Size RenderWidgetHostViewBase::GetPhysicalBackingSize() const { 403 gfx::Size RenderWidgetHostViewBase::GetPhysicalBackingSize() const {
404 gfx::Display display = 404 gfx::Screen* screen = gfx::Screen::GetScreen();
405 gfx::Screen::GetScreen()->GetDisplayNearestWindow(GetNativeView()); 405 if (!screen)
406 return gfx::Size();
407 gfx::Display display = screen->GetDisplayNearestWindow(GetNativeView());
406 return gfx::ScaleToCeiledSize(GetRequestedRendererSize(), 408 return gfx::ScaleToCeiledSize(GetRequestedRendererSize(),
407 display.device_scale_factor()); 409 display.device_scale_factor());
408 } 410 }
409 411
410 bool RenderWidgetHostViewBase::DoTopControlsShrinkBlinkSize() const { 412 bool RenderWidgetHostViewBase::DoTopControlsShrinkBlinkSize() const {
411 return false; 413 return false;
412 } 414 }
413 415
414 float RenderWidgetHostViewBase::GetTopControlsHeight() const { 416 float RenderWidgetHostViewBase::GetTopControlsHeight() const {
415 return 0.f; 417 return 0.f;
(...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after
695 } 697 }
696 698
697 void RenderWidgetHostViewBase::TransformPointToLocalCoordSpace( 699 void RenderWidgetHostViewBase::TransformPointToLocalCoordSpace(
698 const gfx::Point& point, 700 const gfx::Point& point,
699 cc::SurfaceId original_surface, 701 cc::SurfaceId original_surface,
700 gfx::Point* transformed_point) { 702 gfx::Point* transformed_point) {
701 *transformed_point = point; 703 *transformed_point = point;
702 } 704 }
703 705
704 } // namespace content 706 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698