Chromium Code Reviews| Index: chrome/browser/resources/chromeos/login/user_pod_row.js |
| diff --git a/chrome/browser/resources/chromeos/login/user_pod_row.js b/chrome/browser/resources/chromeos/login/user_pod_row.js |
| index eafb56a9dde2bee0411a7b546bdc605ffa887a5a..d8edc671c65d66659c18e10786343fff088310ae 100644 |
| --- a/chrome/browser/resources/chromeos/login/user_pod_row.js |
| +++ b/chrome/browser/resources/chromeos/login/user_pod_row.js |
| @@ -299,8 +299,12 @@ cr.define('login', function() { |
| * Updates the user pod element. |
| */ |
| update: function() { |
| - this.imageElement.src = 'chrome://userimage/' + this.user.username + |
| - '?id=' + UserPod.userImageSalt_[this.user.username]; |
| + if (this.user.isDesktopScreen) { |
| + this.imageElement.src = this.user.userImage; |
| + } else { |
| + this.imageElement.src = 'chrome://userimage/' + this.user.username + |
| + '?id=' + UserPod.userImageSalt_[this.user.username]; |
| + } |
|
Roger Tawa OOO till Jul 10th
2013/06/05 18:53:56
Would it be possible to derive something like Desk
noms
2013/06/06 19:01:36
Done.
|
| this.nameElement.textContent = this.user_.displayName; |
| this.actionBoxAreaElement.hidden = this.user_.publicAccount; |
| @@ -434,6 +438,12 @@ cr.define('login', function() { |
| * @return {boolean} True if activated successfully. |
| */ |
| activate: function() { |
| + if (this.user.isDesktopScreen) { |
| + Oobe.launchUser(this.user.emailAddress, |
| + this.user.displayName); |
| + return; |
| + } |
| + |
| if (!this.signinButtonElement.hidden) { |
| // Switch to Gaia signin. |
| this.showSigninUI(); |
| @@ -566,6 +576,17 @@ cr.define('login', function() { |
| handleMouseDown_: function(e) { |
| if (this.parentNode.disabled) |
| return; |
| + |
| + // We don't want to sign in until the user presses |
| + // the button. Just activate the pod. |
| + if (this.user.isDesktopScreen) { |
| + Oobe.clearErrors(); |
| + this.disabled = true; |
| + this.parentNode.lastFocusedPod_ = |
| + this.parentNode.getPodWithUsername_(this.user.emailAddress); |
| + return; |
| + } |
| + |
|
Roger Tawa OOO till Jul 10th
2013/06/05 18:53:56
Should probably move this file to a directory that
noms
2013/06/06 19:01:36
This file is actually part of pretty large codebas
|
| if (!this.signinButtonElement.hidden && !this.isActionBoxMenuActive) { |
| this.showSigninUI(); |
| // Prevent default so that we don't trigger 'focus' event. |