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

Unified Diff: chrome/browser/resources/file_manager/js/file_manager.js

Issue 8271025: Moved mobile activation into its own modal dialog (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 9 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/browser/resources/file_manager/js/file_manager.js
===================================================================
--- chrome/browser/resources/file_manager/js/file_manager.js (revision 106060)
+++ chrome/browser/resources/file_manager/js/file_manager.js (working copy)
@@ -58,9 +58,7 @@
this.document_ = dialogDom.ownerDocument;
this.dialogType_ = this.params_.type || FileManager.DialogType.FULL_PAGE;
- this.alert = new cr.ui.dialogs.AlertDialog(this.dialogDom_);
- this.confirm = new cr.ui.dialogs.ConfirmDialog(this.dialogDom_);
- this.prompt = new cr.ui.dialogs.PromptDialog(this.dialogDom_);
+ this.initDialogs_();
// TODO(dgozman): This will be changed to LocaleInfo.
this.locale_ = new v8Locale(navigator.language);
@@ -544,6 +542,17 @@
}
/**
+ * One-time initialization of dialogs.
+ */
+ FileManager.prototype.initDialogs_ = function() {
+ cr.ui.dialogs.BaseDialog.OK_LABEL = str('OK_LABEL');
+ cr.ui.dialogs.BaseDialog.CANCEL_LABEL = str('CANCEL_LABEL');
+ this.alert = new cr.ui.dialogs.AlertDialog(this.dialogDom_);
+ this.confirm = new cr.ui.dialogs.ConfirmDialog(this.dialogDom_);
+ this.prompt = new cr.ui.dialogs.PromptDialog(this.dialogDom_);
+ };
+
+ /**
* One-time initialization of various DOM nodes.
*/
FileManager.prototype.initDom_ = function() {
@@ -660,7 +669,7 @@
if (!('cachedIconType_' in entry))
entry.cachedIconType_ = this.computeIconType_(entry);
return entry.cachedIconType_;
- }
+ };
/**
* Extract extension from the file name and cat it to to lower case.

Powered by Google App Engine
This is Rietveld 408576698