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

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

Issue 1701163003: Hide non-native volumes when saving files from the browser. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fix tests Created 4 years, 10 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/dialog_action_controller.js
diff --git a/ui/file_manager/file_manager/foreground/js/dialog_action_controller.js b/ui/file_manager/file_manager/foreground/js/dialog_action_controller.js
index 1aa179f85ea017a97ef1f8a36fe5aa5bcdc995f2..5fc24d99743a9652163b8537c5f6184304d722bd 100644
--- a/ui/file_manager/file_manager/foreground/js/dialog_action_controller.js
+++ b/ui/file_manager/file_manager/foreground/js/dialog_action_controller.js
@@ -94,11 +94,11 @@ function DialogActionController(
this.fileTypes_ = launchParam.typeList || [];
/**
- * @type {boolean}
+ * @type {!AllowedPaths}
* @const
* @private
*/
- this.shouldReturnLocalPath_ = launchParam.shouldReturnLocalPath;
+ this.allowedPaths_ = launchParam.allowedPaths;
/**
* Bound function for onCancel_.
@@ -287,14 +287,14 @@ DialogActionController.prototype.selectFilesAndClose_ = function(selection) {
if (selection.multiple) {
chrome.fileManagerPrivate.selectFiles(
selection.urls,
- this.shouldReturnLocalPath_,
+ this.allowedPaths_ === AllowedPaths.NATIVE_PATH,
onFileSelected);
} else {
chrome.fileManagerPrivate.selectFile(
selection.urls[0],
selection.filterIndex,
this.dialogType_ !== DialogType.SELECT_SAVEAS_FILE /* for opening */,
- this.shouldReturnLocalPath_,
+ this.allowedPaths_ === AllowedPaths.NATIVE_PATH,
onFileSelected);
}
}.bind(this);

Powered by Google App Engine
This is Rietveld 408576698