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

Unified Diff: remoting/android/java/src/org/chromium/chromoting/accountswitcher/AccountSwitcher.java

Issue 1369903002: Android Chromoting: Add hooks for the official account-switcher (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add hooks for Google Play Services connection errors. Created 5 years, 3 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: remoting/android/java/src/org/chromium/chromoting/accountswitcher/AccountSwitcher.java
diff --git a/remoting/android/java/src/org/chromium/chromoting/accountswitcher/AccountSwitcher.java b/remoting/android/java/src/org/chromium/chromoting/accountswitcher/AccountSwitcher.java
index 5efccca7bd373650294dff39e03c56192631ee3a..c422a27c225f00489619760514ff33af0280ee65 100644
--- a/remoting/android/java/src/org/chromium/chromoting/accountswitcher/AccountSwitcher.java
+++ b/remoting/android/java/src/org/chromium/chromoting/accountswitcher/AccountSwitcher.java
@@ -4,6 +4,7 @@
package org.chromium.chromoting.accountswitcher;
+import android.content.Intent;
import android.view.View;
/** Common interface for account-switcher implementations. */
@@ -72,4 +73,16 @@ public interface AccountSwitcher {
* that a valid account is selected, or that the list is empty.
*/
void reloadAccounts();
+
+ /**
+ * This should be called from the controlling activity's onActivityResult() method. It allows
+ * the account-switcher implementation to launch a child Activity and handle the result.
+ */
+ void onActivityResult(int requestCode, int resultCode, Intent data);
+
+ /**
+ * Releases any resources used by the account-switcher. Should be called by the activity's
+ * onDestroy() method.
+ */
+ void destroy();
}

Powered by Google App Engine
This is Rietveld 408576698