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

Unified Diff: ui/file_manager/file_manager/background/js/volume_manager.js

Issue 1215533003: Add a refresh button for providers which do not support watchers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed tests. Created 5 years, 5 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/background/js/volume_manager.js
diff --git a/ui/file_manager/file_manager/background/js/volume_manager.js b/ui/file_manager/file_manager/background/js/volume_manager.js
index d50bdd585e3ce79c40870b75b23534cc19b30a57..c9af84aa7b6372639533cb93db34e1d7f4192205 100644
--- a/ui/file_manager/file_manager/background/js/volume_manager.js
+++ b/ui/file_manager/file_manager/background/js/volume_manager.js
@@ -42,6 +42,7 @@ function VolumeInfo(
extensionId,
hasMedia,
configurable,
+ watchable,
source) {
this.volumeType_ = volumeType;
this.volumeId_ = volumeId;
@@ -85,6 +86,7 @@ function VolumeInfo(
this.extensionId_ = extensionId;
this.hasMedia_ = hasMedia;
this.configurable_ = configurable;
+ this.watchable_ = watchable;
this.source_ = source;
}
@@ -175,6 +177,12 @@ VolumeInfo.prototype = /** @struct */ {
return this.configurable_;
},
/**
+ * @return {boolean} True if the volume is watchable.
+ */
+ get watchable() {
+ return this.watchable_;
+ },
+ /**
* @return {VolumeManagerCommon.Source} Source of the volume's data.
*/
get source() {
@@ -333,6 +341,7 @@ volumeManagerUtil.createVolumeInfo = function(volumeMetadata) {
volumeMetadata.extensionId,
volumeMetadata.hasMedia,
volumeMetadata.configurable,
+ volumeMetadata.watchable,
/** @type {VolumeManagerCommon.Source} */
(volumeMetadata.source));
})
@@ -358,6 +367,7 @@ volumeManagerUtil.createVolumeInfo = function(volumeMetadata) {
volumeMetadata.extensionId,
volumeMetadata.hasMedia,
volumeMetadata.configurable,
+ volumeMetadata.watchable,
/** @type {VolumeManagerCommon.Source} */
(volumeMetadata.source));
});

Powered by Google App Engine
This is Rietveld 408576698