OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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 cr.define('options', function() { | 5 cr.define('options', function() { |
6 const OptionsPage = options.OptionsPage; | 6 const OptionsPage = options.OptionsPage; |
7 | 7 |
8 // Variable to track if a captcha challenge was issued. If this gets set to | 8 // Variable to track if a captcha challenge was issued. If this gets set to |
9 // true, it stays that way until we are told about successful login from | 9 // true, it stays that way until we are told about successful login from |
10 // the browser. This means subsequent errors (like invalid password) are | 10 // the browser. This means subsequent errors (like invalid password) are |
(...skipping 574 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
585 getSignInButton_: function() { | 585 getSignInButton_: function() { |
586 return $('sign-in'); | 586 return $('sign-in'); |
587 }, | 587 }, |
588 | 588 |
589 showAccessCodeRequired_: function() { | 589 showAccessCodeRequired_: function() { |
590 $('password-row').hidden = true; | 590 $('password-row').hidden = true; |
591 $('email-row').hidden = true; | 591 $('email-row').hidden = true; |
592 | 592 |
593 $('access-code-input-row').hidden = false; | 593 $('access-code-input-row').hidden = false; |
594 $('access-code').disabled = false; | 594 $('access-code').disabled = false; |
| 595 $('access-code').focus(); |
595 }, | 596 }, |
596 | 597 |
597 showCaptcha_: function(args) { | 598 showCaptcha_: function(args) { |
598 this.captchaChallengeActive_ = true; | 599 this.captchaChallengeActive_ = true; |
599 | 600 |
600 // The captcha takes up lots of space, so make room. | 601 // The captcha takes up lots of space, so make room. |
601 $('top-blurb-error').hidden = true; | 602 $('top-blurb-error').hidden = true; |
602 $('create-account-div').hidden = true; | 603 $('create-account-div').hidden = true; |
603 | 604 |
604 // It's showtime for the captcha now. | 605 // It's showtime for the captcha now. |
(...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
880 | 881 |
881 SyncSetupOverlay.showStopSyncingUI = function() { | 882 SyncSetupOverlay.showStopSyncingUI = function() { |
882 SyncSetupOverlay.getInstance().showStopSyncingUI_(); | 883 SyncSetupOverlay.getInstance().showStopSyncingUI_(); |
883 }; | 884 }; |
884 | 885 |
885 // Export | 886 // Export |
886 return { | 887 return { |
887 SyncSetupOverlay: SyncSetupOverlay | 888 SyncSetupOverlay: SyncSetupOverlay |
888 }; | 889 }; |
889 }); | 890 }); |
OLD | NEW |