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

Side by Side Diff: components/web_contents_delegate_android/android/java/src/org/chromium/components/web_contents_delegate_android/WebContentsDelegateAndroid.java

Issue 970883002: [Android WebView] Synthesize a fake page loading event on page source modification (Re-land) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed findbugs warning Created 5 years, 9 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 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 package org.chromium.components.web_contents_delegate_android; 5 package org.chromium.components.web_contents_delegate_android;
6 6
7 import android.view.KeyEvent; 7 import android.view.KeyEvent;
8 8
9 import org.chromium.base.CalledByNative; 9 import org.chromium.base.CalledByNative;
10 import org.chromium.base.JNINamespace; 10 import org.chromium.base.JNINamespace;
11 import org.chromium.content_public.browser.InvalidateTypes;
11 import org.chromium.content_public.browser.WebContents; 12 import org.chromium.content_public.browser.WebContents;
12 13
13 /** 14 /**
14 * Java peer of the native class of the same name. 15 * Java peer of the native class of the same name.
15 */ 16 */
16 @JNINamespace("web_contents_delegate_android") 17 @JNINamespace("web_contents_delegate_android")
17 public class WebContentsDelegateAndroid { 18 public class WebContentsDelegateAndroid {
18 19
19 // Equivalent of WebCore::WebConsoleMessage::LevelTip. 20 // Equivalent of WebCore::WebConsoleMessage::LevelTip.
20 public static final int LOG_LEVEL_TIP = 0; 21 public static final int LOG_LEVEL_TIP = 0;
21 // Equivalent of WebCore::WebConsoleMessage::LevelLog. 22 // Equivalent of WebCore::WebConsoleMessage::LevelLog.
22 public static final int LOG_LEVEL_LOG = 1; 23 public static final int LOG_LEVEL_LOG = 1;
23 // Equivalent of WebCore::WebConsoleMessage::LevelWarning. 24 // Equivalent of WebCore::WebConsoleMessage::LevelWarning.
24 public static final int LOG_LEVEL_WARNING = 2; 25 public static final int LOG_LEVEL_WARNING = 2;
25 // Equivalent of WebCore::WebConsoleMessage::LevelError. 26 // Equivalent of WebCore::WebConsoleMessage::LevelError.
26 public static final int LOG_LEVEL_ERROR = 3; 27 public static final int LOG_LEVEL_ERROR = 3;
27 28
28 // Flags passed to the WebContentsDelegateAndroid.navigationStateChanged to tell it 29 // TODO(mnaganov): Remove after getting rid of downstream usages.
29 // what has changed. Should match the values in invalidate_type.h. 30 public static final int INVALIDATE_TYPE_TAB = InvalidateTypes.TAB;
30 // Equivalent of InvalidateTypes::INVALIDATE_TYPE_URL.
31 public static final int INVALIDATE_TYPE_URL = 1 << 0;
32 // Equivalent of InvalidateTypes::INVALIDATE_TYPE_TAB.
33 public static final int INVALIDATE_TYPE_TAB = 1 << 1;
34 // Equivalent of InvalidateTypes::INVALIDATE_TYPE_LOAD.
35 public static final int INVALIDATE_TYPE_LOAD = 1 << 2;
36 // Equivalent of InvalidateTypes::INVALIDATE_TYPE_TITLE.
37 public static final int INVALIDATE_TYPE_TITLE = 1 << 3;
38 31
39 // The most recent load progress callback received from WebContents, as a pe rcentage. 32 // The most recent load progress callback received from WebContents, as a pe rcentage.
40 // Initialize to 100 to indicate that we're not in a loading state. 33 // Initialize to 100 to indicate that we're not in a loading state.
41 private int mMostRecentProgress = 100; 34 private int mMostRecentProgress = 100;
42 35
43 public int getMostRecentProgress() { 36 public int getMostRecentProgress() {
44 return mMostRecentProgress; 37 return mMostRecentProgress;
45 } 38 }
46 39
47 /** 40 /**
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
162 155
163 @CalledByNative 156 @CalledByNative
164 public void toggleFullscreenModeForTab(boolean enterFullscreen) { 157 public void toggleFullscreenModeForTab(boolean enterFullscreen) {
165 } 158 }
166 159
167 @CalledByNative 160 @CalledByNative
168 public boolean isFullscreenForTabOrPending() { 161 public boolean isFullscreenForTabOrPending() {
169 return false; 162 return false;
170 } 163 }
171 } 164 }
OLDNEW
« no previous file with comments | « chrome/android/java/src/org/chromium/chrome/browser/Tab.java ('k') | content/browser/web_contents/web_contents_android.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698