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

Unified Diff: chrome/browser/android/vr_shell/vr_shell.cc

Issue 2842693005: Store physical backing size in ViewAndroid (Closed)
Patch Set: no cvc/eventf Created 3 years, 8 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: chrome/browser/android/vr_shell/vr_shell.cc
diff --git a/chrome/browser/android/vr_shell/vr_shell.cc b/chrome/browser/android/vr_shell/vr_shell.cc
index 83360fb6de812064333aa0e8bb6f447a605a9bda..02a2fbfec972c457b477673ec672969aaddf975d 100644
--- a/chrome/browser/android/vr_shell/vr_shell.cc
+++ b/chrome/browser/android/vr_shell/vr_shell.cc
@@ -407,6 +407,18 @@ void VrShell::AppButtonPressed() {
ui_->HandleAppButtonClicked();
}
+void VrShell::OnPhysicalBackingSizeChanged(
+ JNIEnv* env,
+ const JavaParamRef<jobject>& obj,
+ const JavaParamRef<jobject>& jweb_contents,
+ jint width,
+ jint height) {
+ content::WebContents* web_contents =
+ content::WebContents::FromJavaWebContents(jweb_contents);
+ gfx::Size size(width, height);
+ web_contents->GetNativeView()->OnPhysicalBackingSizeChanged(size);
+}
+
void VrShell::ContentPhysicalBoundsChanged(JNIEnv* env,
const JavaParamRef<jobject>& object,
jint width,

Powered by Google App Engine
This is Rietveld 408576698