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

Unified Diff: ui/file_manager/file_manager/foreground/js/ui/multi_profile_share_dialog.js

Issue 571453002: Correct indentation, JSDoc, etc... to comply with closure linter. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 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: ui/file_manager/file_manager/foreground/js/ui/multi_profile_share_dialog.js
diff --git a/ui/file_manager/file_manager/foreground/js/ui/multi_profile_share_dialog.js b/ui/file_manager/file_manager/foreground/js/ui/multi_profile_share_dialog.js
index 5145e51fcf1d53f81fa0ce405840d5a91e4436f6..f8251bdd3468a725f56641e6737a21c8ea26b91a 100644
--- a/ui/file_manager/file_manager/foreground/js/ui/multi_profile_share_dialog.js
+++ b/ui/file_manager/file_manager/foreground/js/ui/multi_profile_share_dialog.js
@@ -46,8 +46,8 @@ function MultiProfileShareDialog(parentNode) {
this.currentProfileId_ = new Promise(function(callback) {
chrome.fileManagerPrivate.getProfiles(
function(profiles, currentId, displayedId) {
- callback(currentId);
- });
+ callback(currentId);
+ });
});
}
@@ -74,27 +74,26 @@ MultiProfileShareDialog.prototype = {
* is already opened, it returns null.
*/
MultiProfileShareDialog.prototype.show = function(plural) {
- return this.currentProfileId_.
- then(function(currentProfileId) {
- return new Promise(function(fulfill, reject) {
- this.shareTypeSelect_.selectedIndex = 0;
- this.mailLabel_.textContent = currentProfileId;
- var result = FileManagerDialogBase.prototype.showOkCancelDialog.call(
- this,
- str(plural ?
- 'MULTI_PROFILE_SHARE_DIALOG_TITLE_PLURAL' :
- 'MULTI_PROFILE_SHARE_DIALOG_TITLE'),
- str(plural ?
- 'MULTI_PROFILE_SHARE_DIALOG_MESSAGE_PLURAL' :
- 'MULTI_PROFILE_SHARE_DIALOG_MESSAGE'),
- function() {
- fulfill(this.shareTypeSelect_.value);
- }.bind(this),
- function() {
- fulfill(MultiProfileShareDialog.Result.CANCEL);
- });
- if (!result)
- reject(new Error('Another dialog has already shown.'));
- }.bind(this));
- }.bind(this));
+ return this.currentProfileId_.then(function(currentProfileId) {
+ return new Promise(function(fulfill, reject) {
+ this.shareTypeSelect_.selectedIndex = 0;
+ this.mailLabel_.textContent = currentProfileId;
+ var result = FileManagerDialogBase.prototype.showOkCancelDialog.call(
+ this,
+ str(plural ?
+ 'MULTI_PROFILE_SHARE_DIALOG_TITLE_PLURAL' :
+ 'MULTI_PROFILE_SHARE_DIALOG_TITLE'),
+ str(plural ?
+ 'MULTI_PROFILE_SHARE_DIALOG_MESSAGE_PLURAL' :
+ 'MULTI_PROFILE_SHARE_DIALOG_MESSAGE'),
+ function() {
+ fulfill(this.shareTypeSelect_.value);
+ }.bind(this),
+ function() {
+ fulfill(MultiProfileShareDialog.Result.CANCEL);
+ });
+ if (!result)
+ reject(new Error('Another dialog has already shown.'));
+ }.bind(this));
+ }.bind(this));
};

Powered by Google App Engine
This is Rietveld 408576698