Index: chrome/browser/resources/md_user_manager/user_manager.js |
diff --git a/chrome/browser/resources/md_user_manager/user_manager.js b/chrome/browser/resources/md_user_manager/user_manager.js |
index 6864f2c15aee827e7fb3d549e0cf1d4bd0b9f64e..24e329aedb5316dda10467e342773947191324b1 100644 |
--- a/chrome/browser/resources/md_user_manager/user_manager.js |
+++ b/chrome/browser/resources/md_user_manager/user_manager.js |
@@ -66,6 +66,7 @@ cr.define('cr.ui', function() { |
signin.ProfileBrowserProxyImpl.getInstance().initializeUserManager( |
window.location.hash); |
+ cr.addWebUIListener('show-error-dialog', cr.ui.UserManager.showErrorDialog); |
}; |
/** |
@@ -132,6 +133,14 @@ cr.define('cr.ui', function() { |
DisplayManager.clearErrors(); |
}; |
+ /** |
+ * Shows the error dialog populated with the given message. |
+ * @param {string} message Error message to show. |
+ */ |
+ UserManager.showErrorDialog = function(message) { |
+ document.querySelector('error-dialog').show(message); |
+ }; |
+ |
// Export |
return { |
UserManager: UserManager |