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

Unified Diff: chrome/common/extensions/api/identity.idl

Issue 27283002: Identity API: Add chrome.identity.onSignInChanged routing and IDL (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: AccountInfo documentation Created 7 years, 2 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: chrome/common/extensions/api/identity.idl
diff --git a/chrome/common/extensions/api/identity.idl b/chrome/common/extensions/api/identity.idl
index cba84e492544286f5df9d103c1286dca1734bc75..b21352fba24d27dcfc55c01ed625af9ff6fb0f2f 100644
--- a/chrome/common/extensions/api/identity.idl
+++ b/chrome/common/extensions/api/identity.idl
@@ -39,6 +39,16 @@ namespace identity {
boolean? interactive;
};
+ dictionary AccountInfo {
+ // A unique identifier for the account. This ID will not change
+ // for the lifetime of the account.
+ DOMString id;
+ // The email address associated with the account. APIs that return
+ // <code>AccountInfo</code> objects will populate this field if
+ // the app has the <code>identity.email</code> permission.
+ DOMString? email;
+ };
+
callback GetAuthTokenCallback = void (optional DOMString token);
callback InvalidateAuthTokenCallback = void ();
callback LaunchWebAuthFlowCallback = void (optional DOMString responseUrl);
@@ -85,6 +95,10 @@ namespace identity {
// |callback| : Called with the URL redirected back to your application.
static void launchWebAuthFlow(WebAuthFlowDetails details,
LaunchWebAuthFlowCallback callback);
- }
- ;
+ };
+
+ interface Events {
+ // Fired when signin state changes for an account on the user's profile.
+ static void onSignInChanged(AccountInfo account, boolean signedIn);
+ };
};

Powered by Google App Engine
This is Rietveld 408576698