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

Side by Side Diff: chrome/android/java/src/org/chromium/chrome/browser/tab/Tab.java

Issue 1624583003: Reload Lo-Fi images inline instead of reloading the whole page (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: creis comments 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 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 package org.chromium.chrome.browser.tab; 5 package org.chromium.chrome.browser.tab;
6 6
7 import android.app.Activity; 7 import android.app.Activity;
8 import android.content.Context; 8 import android.content.Context;
9 import android.content.Intent; 9 import android.content.Intent;
10 import android.content.res.Resources; 10 import android.content.res.Resources;
(...skipping 906 matching lines...) Expand 10 before | Expand all | Expand 10 after
917 * Reloads the current page content with Lo-Fi off. 917 * Reloads the current page content with Lo-Fi off.
918 * This version ignores the cache and reloads from the network. 918 * This version ignores the cache and reloads from the network.
919 */ 919 */
920 public void reloadDisableLoFi() { 920 public void reloadDisableLoFi() {
921 if (getWebContents() != null) { 921 if (getWebContents() != null) {
922 getWebContents().getNavigationController().reloadDisableLoFi(true); 922 getWebContents().getNavigationController().reloadDisableLoFi(true);
923 } 923 }
924 } 924 }
925 925
926 /** 926 /**
927 * Reloads all the Lo-Fi images in this Tab's WebContents.
928 * This version ignores the cache and reloads from the network.
929 */
930 public void reloadLoFiImages() {
931 if (getWebContents() != null) {
932 getWebContents().reloadLoFiImages();
933 }
934 }
935
936 /**
927 * @return Whether or not the loading and rendering of the page is done. 937 * @return Whether or not the loading and rendering of the page is done.
928 */ 938 */
929 @VisibleForTesting 939 @VisibleForTesting
930 public boolean isLoadingAndRenderingDone() { 940 public boolean isLoadingAndRenderingDone() {
931 return isReady() && getProgress() >= CONSIDERED_READY_LOAD_PERCENTAGE; 941 return isReady() && getProgress() >= CONSIDERED_READY_LOAD_PERCENTAGE;
932 } 942 }
933 943
934 /** Stop the current navigation. */ 944 /** Stop the current navigation. */
935 public void stopLoading() { 945 public void stopLoading() {
936 if (isLoading()) { 946 if (isLoading()) {
(...skipping 1974 matching lines...) Expand 10 before | Expand all | Expand 10 after
2911 private native void nativeSetInterceptNavigationDelegate(long nativeTabAndro id, 2921 private native void nativeSetInterceptNavigationDelegate(long nativeTabAndro id,
2912 InterceptNavigationDelegate delegate); 2922 InterceptNavigationDelegate delegate);
2913 private native void nativeAttachToTabContentManager(long nativeTabAndroid, 2923 private native void nativeAttachToTabContentManager(long nativeTabAndroid,
2914 TabContentManager tabContentManager); 2924 TabContentManager tabContentManager);
2915 private native void nativeAttachOverlayContentViewCore(long nativeTabAndroid , 2925 private native void nativeAttachOverlayContentViewCore(long nativeTabAndroid ,
2916 ContentViewCore content, boolean visible); 2926 ContentViewCore content, boolean visible);
2917 private native void nativeDetachOverlayContentViewCore(long nativeTabAndroid , 2927 private native void nativeDetachOverlayContentViewCore(long nativeTabAndroid ,
2918 ContentViewCore content); 2928 ContentViewCore content);
2919 private native boolean nativeHasPrerenderedUrl(long nativeTabAndroid, String url); 2929 private native boolean nativeHasPrerenderedUrl(long nativeTabAndroid, String url);
2920 } 2930 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698