Chromium Code Reviews| Index: chrome/browser/resources/file_manager/js/file_manager.js |
| diff --git a/chrome/browser/resources/file_manager/js/file_manager.js b/chrome/browser/resources/file_manager/js/file_manager.js |
| index 494d23fd0c915967b1a60fb7e55994dd9560df83..58ac775d03e653785371223890b9c3b34f3e4879 100644 |
| --- a/chrome/browser/resources/file_manager/js/file_manager.js |
| +++ b/chrome/browser/resources/file_manager/js/file_manager.js |
| @@ -694,7 +694,8 @@ FileManager.prototype = { |
| return; |
| metrics.startInterval('Load.GData'); |
| - chrome.fileBrowserPrivate.addMount('', 'gdata', {}); |
| + chrome.fileBrowserPrivate.addMount('', 'gdata', {}, |
| + function(sourcePath) {}); |
| // This timer could fire before the mount succeeds. We will silently |
| // replace the error message with the correct directory contents. |
| @@ -2630,7 +2631,7 @@ FileManager.prototype = { |
| return; |
| } |
| // Current directory just unmounted. Move to the 'Downloads'. |
| - changeDirectoryTo = this.directoryModel_.getDefaultDirectory(); |
| + changeDirectoryTo = self.directoryModel_.getDefaultDirectory(); |
| } |
| } |
| @@ -2666,8 +2667,12 @@ FileManager.prototype = { |
| // Url in MountCompleted event won't be escaped, so let's make sure |
| // we don't use escaped one in mountRequests_. |
| var unescapedUrl = unescape(urls[index]); |
| - self.mountRequests_.push(unescapedUrl); |
| - chrome.fileBrowserPrivate.addMount(unescapedUrl, 'file', {}); |
| + var callback = function(sourcePath) { |
| + self.mountRequests_.push(self.isOnGData() ? sourcePath : |
| + unescapedUrl); |
| + } |
| + chrome.fileBrowserPrivate.addMount(unescapedUrl, 'file', {}, |
|
tbarzic
2012/04/27 05:44:21
How about:
chrome.fileBrowserPrivate.addMount(unes
hshi
2012/04/27 18:48:56
Done.
|
| + callback); |
| } |
| }); |
| } else if (id == 'format-device') { |