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

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

Issue 10065039: [File Manager] Fix history state for GData folder navigation (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Better comment Created 8 years, 8 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 // 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 3760 matching lines...) Expand 10 before | Expand all | Expand 10 after
3771 this.updateCommonActionButtons_(); 3771 this.updateCommonActionButtons_();
3772 this.updateOkButton_(); 3772 this.updateOkButton_();
3773 this.updateBreadcrumbs_(); 3773 this.updateBreadcrumbs_();
3774 this.updateColumnModel_(); 3774 this.updateColumnModel_();
3775 3775
3776 // Updated when a user clicks on the label of a file, used to detect 3776 // Updated when a user clicks on the label of a file, used to detect
3777 // when a click is eligible to trigger a rename. Can be null, or 3777 // when a click is eligible to trigger a rename. Can be null, or
3778 // an object with 'path' and 'date' properties. 3778 // an object with 'path' and 'date' properties.
3779 this.lastLabelClick_ = null; 3779 this.lastLabelClick_ = null;
3780 3780
3781 var dirEntry = event.newDirEntry; 3781 // Sometimes we rescan the same directory (when mounting GData lazily first,
3782 this.updateLocation_(event.initial, dirEntry.fullPath); 3782 // then for real). Do not update the location then.
3783 if (event.newDirEntry.fullPath != event.previousDirEntry.fullPath) {
3784 this.updateLocation_(event.initial, event.newDirEntry.fullPath);
3785 }
3783 3786
3784 this.checkFreeSpace_(this.getCurrentDirectory()); 3787 this.checkFreeSpace_(this.getCurrentDirectory());
3785 3788
3786 // TODO(dgozman): title may be better than this. 3789 // TODO(dgozman): title may be better than this.
3787 this.document_.title = this.getCurrentDirectory().substr(1); 3790 this.document_.title = this.getCurrentDirectory().substr(1);
3788 3791
3789 var self = this; 3792 var self = this;
3790 3793
3791 if (this.watchedDirectoryUrl_) { 3794 if (this.watchedDirectoryUrl_) {
3792 if (this.watchedDirectoryUrl_ != event.previousDirEntry.toURL()) { 3795 if (this.watchedDirectoryUrl_ != event.previousDirEntry.toURL()) {
(...skipping 904 matching lines...) Expand 10 before | Expand all | Expand 10 after
4697 4700
4698 chrome.fileBrowserPrivate.setGDataPreferences(changeInfo); 4701 chrome.fileBrowserPrivate.setGDataPreferences(changeInfo);
4699 4702
4700 if (oldValue) { 4703 if (oldValue) {
4701 event.target.removeAttribute('checked'); 4704 event.target.removeAttribute('checked');
4702 } else { 4705 } else {
4703 event.target.setAttribute('checked', 'checked'); 4706 event.target.setAttribute('checked', 'checked');
4704 } 4707 }
4705 }; 4708 };
4706 })(); 4709 })();
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