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

Unified Diff: chrome/browser/resources/file_manager/foreground/js/directory_tree.js

Issue 101243003: Remove getCurrentDirectoryURL and getCurrentDirPath from directory_model.js (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years 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: chrome/browser/resources/file_manager/foreground/js/directory_tree.js
diff --git a/chrome/browser/resources/file_manager/foreground/js/directory_tree.js b/chrome/browser/resources/file_manager/foreground/js/directory_tree.js
index 8405a207d0ad901df4b892d69665408abf66cffb..9869f9597132031120e107bdec1932e9af375258 100644
--- a/chrome/browser/resources/file_manager/foreground/js/directory_tree.js
+++ b/chrome/browser/resources/file_manager/foreground/js/directory_tree.js
@@ -374,8 +374,11 @@ DirectoryItem.prototype.doDropTargetAction = function() {
* Executes the assigned action. DirectoryItem performs changeDirectory.
*/
DirectoryItem.prototype.doAction = function() {
- if (this.fullPath !== this.directoryModel_.getCurrentDirPath())
+ // TODO(mtomasz, yoshiki): Do not use fullPaths here, but Entry instead.
+ if (!this.directoryModel_.getCurrentDirEntry() ||
+ this.fullPath !== this.directoryModel_.getCurrentDirEntry().fullPath) {
this.directoryModel_.changeDirectory(this.fullPath);
+ }
};
/**

Powered by Google App Engine
This is Rietveld 408576698