X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=src%2Fchrome%2Fbrowser%2Fresources%2Ffile_manager%2Fforeground%2Fjs%2Fui%2Ffile_manager_ui.js;h=a1e085dc14a5131ab6a961c7b3d83e6e03fa4590;hb=ff3e2503a20db9193d323c1d19c38c68004dec4a;hp=fba040268f722d267ada8ec89e76afd32edc0779;hpb=7338fba38ba696536d1cc9d389afd716a6ab2fe6;p=platform%2Fframework%2Fweb%2Fcrosswalk.git diff --git a/src/chrome/browser/resources/file_manager/foreground/js/ui/file_manager_ui.js b/src/chrome/browser/resources/file_manager/foreground/js/ui/file_manager_ui.js index fba0402..a1e085d 100644 --- a/src/chrome/browser/resources/file_manager/foreground/js/ui/file_manager_ui.js +++ b/src/chrome/browser/resources/file_manager/foreground/js/ui/file_manager_ui.js @@ -101,7 +101,7 @@ var FileManagerUI = function(element, dialogType) { Object.seal(this); // Initialize the header. - this.updateProfileBatch(); + this.updateProfileBadge(); this.element_.querySelector('#app-name').innerText = chrome.runtime.getManifest().name; @@ -191,9 +191,9 @@ FileManagerUI.prototype.initAdditionalUI = function() { }; /** - * Updates visibility and image of the profile batch. + * Updates visibility and image of the profile badge. */ -FileManagerUI.prototype.updateProfileBatch = function() { +FileManagerUI.prototype.updateProfileBadge = function() { if (this.dialogType_ !== DialogType.FULL_PAGE) return; @@ -203,16 +203,16 @@ FileManagerUI.prototype.updateProfileBatch = function() { var imageUri; if (currentId !== displayedId) { for (var i = 0; i < profiles.length; i++) { - if (profiles[i].profileId !== currentId) { + if (profiles[i].profileId === currentId) { imageUri = profiles[i].imageUri; break; } } } - var profileBatch = this.element_.querySelector('#profile-batch'); + var profileBadge = this.element_.querySelector('#profile-badge'); if (imageUri) - profileBatch.setAttribute('src', imageUri); + profileBadge.setAttribute('src', imageUri); else - profileBatch.removeAttribute('src'); + profileBadge.removeAttribute('src'); }.bind(this)); };