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

Unified Diff: android_webview/java/src/org/chromium/android_webview/AwContents.java

Issue 943633003: [WebView] Remove onFailure from VisualStateCallback. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
Index: android_webview/java/src/org/chromium/android_webview/AwContents.java
diff --git a/android_webview/java/src/org/chromium/android_webview/AwContents.java b/android_webview/java/src/org/chromium/android_webview/AwContents.java
index 8d0d278c0f250dc7a8492da604d3ef823ecbe74f..375e065a61c465188f79eec299670c2a0667c578 100644
--- a/android_webview/java/src/org/chromium/android_webview/AwContents.java
+++ b/android_webview/java/src/org/chromium/android_webview/AwContents.java
@@ -184,13 +184,14 @@ public class AwContents implements SmartClipProvider,
/**
* Visual state callback, see {@link #insertVisualStateCallback} for details.
*
- * <p>The {@code requestId} is the id passed to {@link AwContents#insertVisualStateCallback}
- * which can be used to match requests with the corresponding callbacks.
*/
@VisibleForTesting
public abstract static class VisualStateCallback {
+ /**
+ * @param requestId the id passed to {@link AwContents#insertVisualStateCallback}
+ * which can be used to match requests with the corresponding callbacks.
+ */
public abstract void onComplete(long requestId);
- public abstract void onFailure(long requestId);
}
private long mNativeAwContents;
@@ -2177,17 +2178,13 @@ public class AwContents implements SmartClipProvider,
*/
@CalledByNative
public void invokeVisualStateCallback(
- final VisualStateCallback callback, final long requestId, final boolean result) {
+ final VisualStateCallback callback, final long requestId) {
// Posting avoids invoking the callback inside invoking_composite_
// (see synchronous_compositor_impl.cc and crbug/452530).
mContainerView.getHandler().post(new Runnable() {
@Override
public void run() {
- if (result) {
- callback.onComplete(requestId);
- } else {
- callback.onFailure(requestId);
- }
+ callback.onComplete(requestId);
}
});
}

Powered by Google App Engine
This is Rietveld 408576698