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

Unified Diff: customtabs/src/android/support/customtabs/CustomTabsService.java

Issue 1559043005: Update support lib to last released state (Closed) Base URL: https://chromium.googlesource.com/external/github.com/GoogleChrome/custom-tabs-client.git@master
Patch Set: Added aidl changes Created 4 years, 12 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: customtabs/src/android/support/customtabs/CustomTabsService.java
diff --git a/customtabs/src/android/support/customtabs/CustomTabsService.java b/customtabs/src/android/support/customtabs/CustomTabsService.java
index f0e7ea7d4d5bf5e5e1277d24f33185832a5bd96c..25697c5e3bdb35c3e411e670ee4456a16a5dcd46 100644
--- a/customtabs/src/android/support/customtabs/CustomTabsService.java
+++ b/customtabs/src/android/support/customtabs/CustomTabsService.java
@@ -23,7 +23,7 @@ import android.os.Bundle;
import android.os.IBinder;
import android.os.IBinder.DeathRecipient;
import android.os.RemoteException;
-import android.util.ArrayMap;
+import android.support.v4.util.ArrayMap;
import java.util.List;
import java.util.Map;
@@ -90,6 +90,12 @@ import java.util.NoSuchElementException;
public Bundle extraCommand(String commandName, Bundle args) {
return CustomTabsService.this.extraCommand(commandName, args);
}
+
+ @Override
+ public boolean updateVisuals(ICustomTabsCallback callback, Bundle bundle) {
+ return CustomTabsService.this.updateVisuals(
+ new CustomTabsSessionToken(callback), bundle);
+ }
};
@Override
@@ -176,4 +182,15 @@ import java.util.NoSuchElementException;
* @return The result {@link Bundle}, or null.
*/
protected abstract Bundle extraCommand(String commandName, Bundle args);
+
+ /**
+ * Updates the visuals of custom tabs for the given session. Will only succeed if the given
+ * session matches the currently active one.
+ * @param sessionToken The currently active session that the custom tab belongs to.
+ * @param bundle The action button configuration bundle. This bundle should be constructed
+ * with the same structure in {@link CustomTabsIntent.Builder}.
+ * @return Whether the operation was successful.
+ */
+ protected abstract boolean updateVisuals(CustomTabsSessionToken sessionToken,
+ Bundle bundle);
}

Powered by Google App Engine
This is Rietveld 408576698