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

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

Issue 1304063014: cc: Plumbing for BeginFrameSource based on Surfaces (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: NOTREACHED for WebView; NOTIMPLEMENTED elsewhere Created 5 years, 2 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_android.h" 5 #include "content/browser/renderer_host/render_widget_host_view_android.h"
6 6
7 #include <android/bitmap.h> 7 #include <android/bitmap.h>
8 8
9 #include "base/android/build_info.h" 9 #include "base/android/build_info.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
(...skipping 964 matching lines...) Expand 10 before | Expand all | Expand 10 after
975 void RenderWidgetHostViewAndroid::ReturnResources( 975 void RenderWidgetHostViewAndroid::ReturnResources(
976 const cc::ReturnedResourceArray& resources) { 976 const cc::ReturnedResourceArray& resources) {
977 if (resources.empty()) 977 if (resources.empty())
978 return; 978 return;
979 std::copy(resources.begin(), resources.end(), 979 std::copy(resources.begin(), resources.end(),
980 std::back_inserter(surface_returned_resources_)); 980 std::back_inserter(surface_returned_resources_));
981 if (!ack_callbacks_.size()) 981 if (!ack_callbacks_.size())
982 SendReturnedDelegatedResources(last_output_surface_id_); 982 SendReturnedDelegatedResources(last_output_surface_id_);
983 } 983 }
984 984
985 void RenderWidgetHostViewAndroid::SetBeginFrameSource(
986 cc::BeginFrameSource* begin_frame_source) {
987 // TODO(tansell): Hook this up.
988 NOTIMPLEMENTED();
989 }
990
985 void RenderWidgetHostViewAndroid::DestroyDelegatedContent() { 991 void RenderWidgetHostViewAndroid::DestroyDelegatedContent() {
986 RemoveLayers(); 992 RemoveLayers();
987 frame_provider_ = NULL; 993 frame_provider_ = NULL;
988 if (!surface_id_.is_null()) { 994 if (!surface_id_.is_null()) {
989 DCHECK(surface_factory_.get()); 995 DCHECK(surface_factory_.get());
990 surface_factory_->Destroy(surface_id_); 996 surface_factory_->Destroy(surface_id_);
991 surface_id_ = cc::SurfaceId(); 997 surface_id_ = cc::SurfaceId();
992 } 998 }
993 layer_ = NULL; 999 layer_ = NULL;
994 } 1000 }
(...skipping 1005 matching lines...) Expand 10 before | Expand all | Expand 10 after
2000 results->orientationAngle = display.RotationAsDegree(); 2006 results->orientationAngle = display.RotationAsDegree();
2001 results->orientationType = 2007 results->orientationType =
2002 RenderWidgetHostViewBase::GetOrientationTypeForMobile(display); 2008 RenderWidgetHostViewBase::GetOrientationTypeForMobile(display);
2003 gfx::DeviceDisplayInfo info; 2009 gfx::DeviceDisplayInfo info;
2004 results->depth = info.GetBitsPerPixel(); 2010 results->depth = info.GetBitsPerPixel();
2005 results->depthPerComponent = info.GetBitsPerComponent(); 2011 results->depthPerComponent = info.GetBitsPerComponent();
2006 results->isMonochrome = (results->depthPerComponent == 0); 2012 results->isMonochrome = (results->depthPerComponent == 0);
2007 } 2013 }
2008 2014
2009 } // namespace content 2015 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698