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

Unified Diff: third_party/closure_compiler/externs/passwords_private.js

Issue 1142693003: Implement the chrome.passwordsPrivate API. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: stevenjb comment. Created 5 years, 6 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
« no previous file with comments | « extensions/browser/extension_function_histogram_value.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/closure_compiler/externs/passwords_private.js
diff --git a/third_party/closure_compiler/externs/passwords_private.js b/third_party/closure_compiler/externs/passwords_private.js
index 94a528baf34c158df77f92977bd529e73b104a00..0679980fce4cf88e6d80417abbc5f8de5d8955cf 100644
--- a/third_party/closure_compiler/externs/passwords_private.js
+++ b/third_party/closure_compiler/externs/passwords_private.js
@@ -29,6 +29,15 @@ var LoginPair;
var PasswordUiEntry;
/**
+ * @typedef {{
+ * loginPair: LoginPair,
+ * plaintextPassword: string
+ * }}
+ * @see https://developer.chrome.com/extensions/passwordsPrivate#type-PlaintextPasswordEventParameters
+ */
+var PlaintextPasswordEventParameters;
+
+/**
* Determines whether account's passwords can be managed via
* https://passwords.google.com/settings/passwords.
* @param {function(boolean):void} callback Callback which will be passed the
@@ -58,13 +67,13 @@ chrome.passwordsPrivate.removePasswordException = function(exceptionUrl) {};
/**
* Returns the plaintext password corresponding to |loginPair|. Note that on
* some operating systems, this call may result in an OS-level reauthentication.
+ * Once the password has been fetched, it will be returned via the
+ * onPlaintextPasswordRetrieved event.
* @param {LoginPair} loginPair The LoginPair corresponding to the entry whose
* password is to be returned.
- * @param {function(string):void} callback Callback which will be passed the
- * plaintext password.
- * @see https://developer.chrome.com/extensions/passwordsPrivate#method-getPlaintextPassword
+ * @see https://developer.chrome.com/extensions/passwordsPrivate#method-requestPlaintextPassword
*/
-chrome.passwordsPrivate.getPlaintextPassword = function(loginPair, callback) {};
+chrome.passwordsPrivate.requestPlaintextPassword = function(loginPair) {};
/**
* Fired when the saved passwords list has changed, meaning that an entry has
@@ -77,11 +86,17 @@ chrome.passwordsPrivate.onSavedPasswordsListChanged;
/**
* Fired when the password exceptions list has changed, meaning that an entry
- * has been added or removed. Note that this event fires as soon as a listener
+ * has been added or removed. Note that this event fires as soon as a listener
* is added.
* @type {!ChromeEvent}
* @see https://developer.chrome.com/extensions/passwordsPrivate#event-onPasswordExceptionsListChanged
*/
chrome.passwordsPrivate.onPasswordExceptionsListChanged;
-
+/**
+ * Fired when a plaintext password has been fetched in response to a call to
+ * chrome.passwordsPrivate.requestPlaintextPassword().
+ * @type {!ChromeEvent}
+ * @see https://developer.chrome.com/extensions/passwordsPrivate#event-onPlaintextPasswordRetrieved
+ */
+chrome.passwordsPrivate.onPlaintextPasswordRetrieved;
« no previous file with comments | « extensions/browser/extension_function_histogram_value.h ('k') | tools/metrics/histograms/histograms.xml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698