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

Unified Diff: content/browser/android/content_view_render_view.cc

Issue 2842693005: Store physical backing size in ViewAndroid (Closed)
Patch Set: no UpdateLayerBounds Created 3 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/android/content_view_render_view.cc
diff --git a/content/browser/android/content_view_render_view.cc b/content/browser/android/content_view_render_view.cc
index 1bd5d25c5a0ea0fdffbb06f6a6dab6823f1b99fe..8c4d4d3c0917815ad233cb69854eca86a92732e6 100644
--- a/content/browser/android/content_view_render_view.cc
+++ b/content/browser/android/content_view_render_view.cc
@@ -71,6 +71,17 @@ void ContentViewRenderView::SetCurrentWebContents(
: scoped_refptr<cc::Layer>());
}
+void ContentViewRenderView::OnPhysicalBackingSizeChanged(
+ JNIEnv* env,
+ const JavaParamRef<jobject>& obj,
+ const JavaParamRef<jobject>& jweb_contents,
+ jint width,
+ jint height) {
+ WebContents* web_contents = WebContents::FromJavaWebContents(jweb_contents);
+ gfx::Size size(width, height);
+ web_contents->GetNativeView()->OnPhysicalBackingSizeChanged(size);
+}
+
void ContentViewRenderView::SurfaceCreated(JNIEnv* env,
const JavaParamRef<jobject>& obj) {
current_surface_format_ = 0;

Powered by Google App Engine
This is Rietveld 408576698