Chromium Code Reviews| 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.exportPath('options'); | 5 cr.exportPath('options'); |
| 6 | 6 |
| 7 /** @typedef {{appsEnforced: boolean, | 7 /** @typedef {{appsEnforced: boolean, |
| 8 * appsRegistered: boolean, | 8 * appsRegistered: boolean, |
| 9 * appsSynced: boolean, | 9 * appsSynced: boolean, |
| 10 * autofillEnforced: boolean, | 10 * autofillEnforced: boolean, |
| (...skipping 809 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 820 showSetupUI_: function() { | 820 showSetupUI_: function() { |
| 821 chrome.send('SyncSetupShowSetupUI'); | 821 chrome.send('SyncSetupShowSetupUI'); |
| 822 chrome.send('coreOptionsUserMetricsAction', ['Options_ShowSyncAdvanced']); | 822 chrome.send('coreOptionsUserMetricsAction', ['Options_ShowSyncAdvanced']); |
| 823 }, | 823 }, |
| 824 | 824 |
| 825 /** | 825 /** |
| 826 * Starts the signin process for the user. Does nothing if the user is | 826 * Starts the signin process for the user. Does nothing if the user is |
| 827 * already signed in. | 827 * already signed in. |
| 828 * @private | 828 * @private |
| 829 */ | 829 */ |
| 830 startSignIn_: function() { | 830 startSignIn_: function(accessPoint) { |
| 831 chrome.send('SyncSetupStartSignIn'); | 831 chrome.send('SyncSetupStartSignIn', [accessPoint]); |
| 832 }, | 832 }, |
| 833 | 833 |
| 834 /** | 834 /** |
| 835 * Forces user to sign out of Chrome for Chrome OS. | 835 * Forces user to sign out of Chrome for Chrome OS. |
| 836 * @private | 836 * @private |
| 837 */ | 837 */ |
| 838 doSignOutOnAuthError_: function() { | 838 doSignOutOnAuthError_: function() { |
| 839 chrome.send('SyncSetupDoSignOutOnAuthError'); | 839 chrome.send('SyncSetupDoSignOutOnAuthError'); |
| 840 }, | 840 }, |
| 841 }; | 841 }; |
| 842 | 842 |
| 843 // These methods are for general consumption. | 843 // These methods are for general consumption. |
| 844 SyncSetupOverlay.closeOverlay = function() { | 844 SyncSetupOverlay.closeOverlay = function() { |
|
Bernhard Bauer
2015/12/04 11:06:24
If you are touching this code already, could you r
gogerald1
2015/12/04 20:49:09
Done.
| |
| 845 SyncSetupOverlay.getInstance().closeOverlay_(); | 845 SyncSetupOverlay.getInstance().closeOverlay_(); |
| 846 }; | 846 }; |
| 847 | 847 |
| 848 SyncSetupOverlay.showSetupUI = function() { | 848 SyncSetupOverlay.showSetupUI = function() { |
| 849 SyncSetupOverlay.getInstance().showSetupUI_(); | 849 SyncSetupOverlay.getInstance().showSetupUI_(); |
| 850 }; | 850 }; |
| 851 | 851 |
| 852 SyncSetupOverlay.startSignIn = function() { | 852 SyncSetupOverlay.startSignIn = function(accessPoint) { |
| 853 SyncSetupOverlay.getInstance().startSignIn_(); | 853 SyncSetupOverlay.getInstance().startSignIn_(accessPoint); |
| 854 }; | 854 }; |
| 855 | 855 |
| 856 SyncSetupOverlay.doSignOutOnAuthError = function() { | 856 SyncSetupOverlay.doSignOutOnAuthError = function() { |
| 857 SyncSetupOverlay.getInstance().doSignOutOnAuthError_(); | 857 SyncSetupOverlay.getInstance().doSignOutOnAuthError_(); |
| 858 }; | 858 }; |
| 859 | 859 |
| 860 SyncSetupOverlay.showSyncSetupPage = function(page, args) { | 860 SyncSetupOverlay.showSyncSetupPage = function(page, args) { |
| 861 SyncSetupOverlay.getInstance().showSyncSetupPage_(page, args); | 861 SyncSetupOverlay.getInstance().showSyncSetupPage_(page, args); |
| 862 }; | 862 }; |
| 863 | 863 |
| 864 SyncSetupOverlay.showCustomizePage = function(args, index) { | 864 SyncSetupOverlay.showCustomizePage = function(args, index) { |
| 865 SyncSetupOverlay.getInstance().showCustomizePage_(args, index); | 865 SyncSetupOverlay.getInstance().showCustomizePage_(args, index); |
| 866 }; | 866 }; |
| 867 | 867 |
| 868 SyncSetupOverlay.showStopSyncingUI = function() { | 868 SyncSetupOverlay.showStopSyncingUI = function() { |
| 869 SyncSetupOverlay.getInstance().showStopSyncingUI_(); | 869 SyncSetupOverlay.getInstance().showStopSyncingUI_(); |
| 870 }; | 870 }; |
| 871 | 871 |
| 872 // Export | 872 // Export |
| 873 return { | 873 return { |
| 874 SyncSetupOverlay: SyncSetupOverlay | 874 SyncSetupOverlay: SyncSetupOverlay |
| 875 }; | 875 }; |
| 876 }); | 876 }); |
| OLD | NEW |