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

Unified Diff: ui/file_manager/file_manager/foreground/js/file_manager.js

Issue 626813002: Files.app: Move updateLocationLine function from FileManager class to the UI class. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | ui/file_manager/file_manager/foreground/js/ui/file_manager_ui.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: ui/file_manager/file_manager/foreground/js/file_manager.js
diff --git a/ui/file_manager/file_manager/foreground/js/file_manager.js b/ui/file_manager/file_manager/foreground/js/file_manager.js
index 504fc4c85a21c0f292c08abca319c4ec2539a821..40200c70b24960fd354ad86de28c71b87b7ce502 100644
--- a/ui/file_manager/file_manager/foreground/js/file_manager.js
+++ b/ui/file_manager/file_manager/foreground/js/file_manager.js
@@ -2661,30 +2661,6 @@ var BOTTOM_MARGIN_FOR_PREVIEW_PANEL_PX = 52;
};
/**
- * Updates the location information displayed on the toolbar.
- * @param {DirectoryEntry=} opt_entry Directory entry to be displayed as
- * current location. Default entry is the current directory.
- * @private
- */
- FileManager.prototype.updateLocationLine_ = function(opt_entry) {
- var entry = opt_entry || this.getCurrentDirectoryEntry();
- // Updates volume icon.
- var location = this.volumeManager_.getLocationInfo(entry);
- if (location && location.rootType && location.isRootEntry) {
- this.ui_.locationVolumeIcon.setAttribute(
- 'volume-type-icon', location.rootType);
- this.ui_.locationVolumeIcon.removeAttribute('volume-subtype');
- } else {
- this.ui_.locationVolumeIcon.setAttribute(
- 'volume-type-icon', location.volumeInfo.volumeType);
- this.ui_.locationVolumeIcon.setAttribute(
- 'volume-subtype', location.volumeInfo.deviceType);
- }
- // Updates breadcrumbs.
- this.ui_.locationBreadcrumbs.show(entry);
- };
-
- /**
* Update the gear menu.
* @private
*/
@@ -2781,7 +2757,8 @@ var BOTTOM_MARGIN_FOR_PREVIEW_PANEL_PX = 52;
this.updateUnformattedVolumeStatus_();
this.updateTitle_();
- this.updateLocationLine_();
+ this.ui_.updateLocationLine(
+ this.volumeManager_, this.getCurrentDirectoryEntry());
var currentEntry = this.getCurrentDirectoryEntry();
this.previewPanel_.currentEntry = util.isFakeEntry(currentEntry) ?
@@ -3875,13 +3852,14 @@ var BOTTOM_MARGIN_FOR_PREVIEW_PANEL_PX = 52;
if (locationInfo && locationInfo.isDriveBased) {
var rootEntry = locationInfo.volumeInfo.displayRoot;
if (rootEntry)
- this.updateLocationLine_(rootEntry);
+ this.ui_.updateLocationLine(this.volumeManager_, rootEntry);
}
};
var hideNoResultsDiv = function() {
noResultsDiv.removeAttribute('show');
- this.updateLocationLine_();
+ this.ui_.updateLocationLine(
+ this.volumeManager_, this.getCurrentDirectoryEntry());
};
this.doSearch(searchString,
« no previous file with comments | « no previous file | ui/file_manager/file_manager/foreground/js/ui/file_manager_ui.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698