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

Side by Side Diff: chrome/browser/resources/file_manager/js/directory_model.js

Issue 9570035: Fix for making gdata drive R/W in UI. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 // If directory files changes too often, don't rescan directory more than once 5 // If directory files changes too often, don't rescan directory more than once
6 // per specified interval 6 // per specified interval
7 const SIMULTANEOUS_RESCAN_INTERVAL = 1000; 7 const SIMULTANEOUS_RESCAN_INTERVAL = 1000;
8 8
9 /** 9 /**
10 * Data model of the file manager. 10 * Data model of the file manager.
(...skipping 118 matching lines...) Expand 10 before | Expand all | Expand 10 after
129 * @type {boolean} 129 * @type {boolean}
130 */ 130 */
131 get readonly() { 131 get readonly() {
132 switch (this.rootType) { 132 switch (this.rootType) {
133 case DirectoryModel.RootType.REMOVABLE: 133 case DirectoryModel.RootType.REMOVABLE:
134 return this.readonly_; 134 return this.readonly_;
135 case DirectoryModel.RootType.ARCHIVE: 135 case DirectoryModel.RootType.ARCHIVE:
136 return true; 136 return true;
137 case DirectoryModel.RootType.DOWNLOADS: 137 case DirectoryModel.RootType.DOWNLOADS:
138 return false; 138 return false;
139 case DirectoryModel.RootType.GDATA:
140 return false;
139 default: 141 default:
140 return true; 142 return true;
141 } 143 }
142 }, 144 },
143 145
144 set readonly(value) { 146 set readonly(value) {
145 if (this.rootType == DirectoryModel.RootType.REMOVABLE) { 147 if (this.rootType == DirectoryModel.RootType.REMOVABLE) {
146 this.readonly_ = !!value; 148 this.readonly_ = !!value;
147 } 149 }
148 }, 150 },
(...skipping 758 matching lines...) Expand 10 before | Expand all | Expand 10 after
907 909
908 recordMetrics_: function() { 910 recordMetrics_: function() {
909 metrics.recordInterval('DirectoryScan'); 911 metrics.recordInterval('DirectoryScan');
910 if (this.dir_.fullPath == 912 if (this.dir_.fullPath ==
911 '/' + DirectoryModel.DOWNLOADS_DIRECTORY) { 913 '/' + DirectoryModel.DOWNLOADS_DIRECTORY) {
912 metrics.recordMediumCount("DownloadsCount", this.list_.length); 914 metrics.recordMediumCount("DownloadsCount", this.list_.length);
913 } 915 }
914 } 916 }
915 }; 917 };
916 918
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698