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

Side by Side Diff: content/browser/web_contents/web_contents_android.cc

Issue 1488653002: Fix scroll restoration when exiting fullscreen mode. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Addressed comments from scheib@ Created 4 years, 11 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 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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/web_contents/web_contents_android.h" 5 #include "content/browser/web_contents/web_contents_android.h"
6 6
7 #include <stdint.h> 7 #include <stdint.h>
8 8
9 #include "base/android/jni_android.h" 9 #include "base/android/jni_android.h"
10 #include "base/android/jni_array.h" 10 #include "base/android/jni_array.h"
(...skipping 424 matching lines...) Expand 10 before | Expand all | Expand 10 after
435 435
436 jboolean WebContentsAndroid::IsRenderWidgetHostViewReady( 436 jboolean WebContentsAndroid::IsRenderWidgetHostViewReady(
437 JNIEnv* env, 437 JNIEnv* env,
438 const JavaParamRef<jobject>& obj) { 438 const JavaParamRef<jobject>& obj) {
439 RenderWidgetHostViewAndroid* view = GetRenderWidgetHostViewAndroid(); 439 RenderWidgetHostViewAndroid* view = GetRenderWidgetHostViewAndroid();
440 return view && view->HasValidFrame(); 440 return view && view->HasValidFrame();
441 } 441 }
442 442
443 void WebContentsAndroid::ExitFullscreen(JNIEnv* env, 443 void WebContentsAndroid::ExitFullscreen(JNIEnv* env,
444 const JavaParamRef<jobject>& obj) { 444 const JavaParamRef<jobject>& obj) {
445 web_contents_->ExitFullscreen(); 445 web_contents_->ExitFullscreen(/*will_cause_resize=*/false);
446 } 446 }
447 447
448 void WebContentsAndroid::UpdateTopControlsState( 448 void WebContentsAndroid::UpdateTopControlsState(
449 JNIEnv* env, 449 JNIEnv* env,
450 const JavaParamRef<jobject>& obj, 450 const JavaParamRef<jobject>& obj,
451 bool enable_hiding, 451 bool enable_hiding,
452 bool enable_showing, 452 bool enable_showing,
453 bool animate) { 453 bool animate) {
454 RenderViewHost* host = web_contents_->GetRenderViewHost(); 454 RenderViewHost* host = web_contents_->GetRenderViewHost();
455 if (!host) 455 if (!host)
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after
693 if (response == READBACK_SUCCESS) 693 if (response == READBACK_SUCCESS)
694 java_bitmap = gfx::ConvertToJavaBitmap(&bitmap); 694 java_bitmap = gfx::ConvertToJavaBitmap(&bitmap);
695 Java_WebContentsImpl_onGetContentBitmapFinished(env, 695 Java_WebContentsImpl_onGetContentBitmapFinished(env,
696 obj->obj(), 696 obj->obj(),
697 callback->obj(), 697 callback->obj(),
698 java_bitmap.obj(), 698 java_bitmap.obj(),
699 response); 699 response);
700 } 700 }
701 701
702 } // namespace content 702 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698