| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 */ var OptionsPage = options.OptionsPage; | 6 /** @const */ var 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 498 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 509 } else { | 509 } else { |
| 510 // We only show the 'Use Default' link if we're not prompting for an | 510 // We only show the 'Use Default' link if we're not prompting for an |
| 511 // existing passphrase. | 511 // existing passphrase. |
| 512 var self = this; | 512 var self = this; |
| 513 this.animateDisableLink_($('use-default-link'), false, function() { | 513 this.animateDisableLink_($('use-default-link'), false, function() { |
| 514 self.showSyncEverythingPage_(); | 514 self.showSyncEverythingPage_(); |
| 515 }); | 515 }); |
| 516 } | 516 } |
| 517 }, | 517 }, |
| 518 | 518 |
| 519 attach_: function() { | |
| 520 chrome.send('SyncSetupAttachHandler'); | |
| 521 }, | |
| 522 | |
| 523 /** | 519 /** |
| 524 * Shows the appropriate sync setup page. | 520 * Shows the appropriate sync setup page. |
| 525 * @param {string} page A page of the sync setup to show. | 521 * @param {string} page A page of the sync setup to show. |
| 526 * @param {object} args Data from the C++ to forward on to the right | 522 * @param {object} args Data from the C++ to forward on to the right |
| 527 * section. | 523 * section. |
| 528 */ | 524 */ |
| 529 showSyncSetupPage_: function(page, args) { | 525 showSyncSetupPage_: function(page, args) { |
| 530 this.setThrobbersVisible_(false); | 526 this.setThrobbersVisible_(false); |
| 531 | 527 |
| 532 // Hide an existing visible overlay (ensuring the close button is not | 528 // Hide an existing visible overlay (ensuring the close button is not |
| (...skipping 437 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 970 | 966 |
| 971 SyncSetupOverlay.showStopSyncingUI = function() { | 967 SyncSetupOverlay.showStopSyncingUI = function() { |
| 972 SyncSetupOverlay.getInstance().showStopSyncingUI_(); | 968 SyncSetupOverlay.getInstance().showStopSyncingUI_(); |
| 973 }; | 969 }; |
| 974 | 970 |
| 975 // Export | 971 // Export |
| 976 return { | 972 return { |
| 977 SyncSetupOverlay: SyncSetupOverlay | 973 SyncSetupOverlay: SyncSetupOverlay |
| 978 }; | 974 }; |
| 979 }); | 975 }); |
| OLD | NEW |