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

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

Issue 9836086: Added logic that will return the result of the first chunk of root feed and continue fetching the r… (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: crash fix 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
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 // Setting the src of an img to an empty string can crash the browser, so we 5 // Setting the src of an img to an empty string can crash the browser, so we
6 // use an empty 1x1 gif instead. 6 // use an empty 1x1 gif instead.
7 7
8 /** 8 /**
9 * FileManager constructor. 9 * FileManager constructor.
10 * 10 *
(...skipping 3452 matching lines...) Expand 10 before | Expand all | Expand 10 after
3463 } 3463 }
3464 chrome.fileBrowserPrivate.removeFileWatch(this.watchedDirectoryUrl_, 3464 chrome.fileBrowserPrivate.removeFileWatch(this.watchedDirectoryUrl_,
3465 function(result) { 3465 function(result) {
3466 if (!result) { 3466 if (!result) {
3467 console.log('Failed to remove file watch'); 3467 console.log('Failed to remove file watch');
3468 } 3468 }
3469 }); 3469 });
3470 this.watchedDirectoryUrl_ = null; 3470 this.watchedDirectoryUrl_ = null;
3471 } 3471 }
3472 3472
3473 if (event.newDirEntry.fullPath != '/' && 3473 if (event.newDirEntry.fullPath != '/') {
3474 DirectoryModel.getRootType(event.newDirEntry.fullPath) != 3474 console.log("Adding watch for : " +event.newDirEntry.fullPath);
3475 DirectoryModel.GDATA_DIRECTORY) { 3475 console.log(event);
satorux1 2012/03/25 00:22:26 remove the debug logging?
zel 2012/03/25 02:06:41 Done.
3476 // Currently file watchers do not work on GData. When they start working
3477 // we should be careful not to watch GData before it is mounted.
3478 this.watchedDirectoryUrl_ = event.newDirEntry.toURL(); 3476 this.watchedDirectoryUrl_ = event.newDirEntry.toURL();
3479 chrome.fileBrowserPrivate.addFileWatch(this.watchedDirectoryUrl_, 3477 chrome.fileBrowserPrivate.addFileWatch(this.watchedDirectoryUrl_,
3480 function(result) { 3478 function(result) {
3481 if (!result) { 3479 if (!result) {
3482 console.log('Failed to add file watch'); 3480 console.log('Failed to add file watch');
3483 this.watchedDirectoryUrl_ = null; 3481 this.watchedDirectoryUrl_ = null;
3484 } 3482 }
3485 }.bind(this)); 3483 }.bind(this));
3486 } 3484 }
3487 3485
(...skipping 795 matching lines...) Expand 10 before | Expand all | Expand 10 after
4283 }); 4281 });
4284 }, onError); 4282 }, onError);
4285 4283
4286 function onError(err) { 4284 function onError(err) {
4287 console.log('Error while checking free space: ' + err); 4285 console.log('Error while checking free space: ' + err);
4288 setTimeout(doCheck, 1000 * 60); 4286 setTimeout(doCheck, 1000 * 60);
4289 } 4287 }
4290 } 4288 }
4291 } 4289 }
4292 })(); 4290 })();
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698