Index: chrome/browser/resources/options/personal_options.js |
diff --git a/chrome/browser/resources/options/personal_options.js b/chrome/browser/resources/options/personal_options.js |
index a0b680987b3aca9de69ab4a7f4be0e0720129c34..2aa626e4d8ea0f0502d210a72bafe2ad1b3470bd 100644 |
--- a/chrome/browser/resources/options/personal_options.js |
+++ b/chrome/browser/resources/options/personal_options.js |
@@ -7,10 +7,6 @@ cr.define('options', function() { |
var OptionsPage = options.OptionsPage; |
var ArrayDataModel = cr.ui.ArrayDataModel; |
- // State variables. |
- var syncEnabled = false; |
- var syncSetupCompleted = false; |
- |
/** |
* Encapsulated handling of personal options page. |
* @constructor |
@@ -31,6 +27,10 @@ cr.define('options', function() { |
// Inherit PersonalOptions from OptionsPage. |
__proto__: options.OptionsPage.prototype, |
+ // State variables. |
+ syncEnabled: false, |
+ syncSetupCompleted: false, |
+ |
// Initialize PersonalOptions page. |
initializePage: function() { |
// Call base class implementation to start preference initialization. |
@@ -292,6 +292,15 @@ cr.define('options', function() { |
}, |
/** |
+ * Get the start/stop sync button DOM element. |
+ * @return {DOMElement} The start/stop sync button. |
+ * @private |
+ */ |
+ getStartStopSyncButton_: function() { |
+ return $('start-stop-sync'); |
+ }, |
+ |
+ /** |
* (Re)loads IMG element with current user account picture. |
*/ |
updateAccountPicture_: function() { |
@@ -330,6 +339,7 @@ cr.define('options', function() { |
// Forward public APIs to private implementations. |
[ |
+ 'getStartStopSyncButton', |
'hideSyncSection', |
'setAutoLoginVisible', |
'setCustomizeSyncButtonEnabled', |
@@ -349,7 +359,7 @@ cr.define('options', function() { |
'updateAccountPicture', |
].forEach(function(name) { |
PersonalOptions[name] = function(value) { |
- PersonalOptions.getInstance()[name + '_'](value); |
+ return PersonalOptions.getInstance()[name + '_'](value); |
}; |
}); |