| Index: chrome/browser/resources/options/browser_options.js
|
| diff --git a/chrome/browser/resources/options/browser_options.js b/chrome/browser/resources/options/browser_options.js
|
| index b6a566a3be651153513ab16e34ab4384553ad2ec..400637ce96364b2dd2e5848534a7713286683469 100644
|
| --- a/chrome/browser/resources/options/browser_options.js
|
| +++ b/chrome/browser/resources/options/browser_options.js
|
| @@ -17,10 +17,11 @@ cr.define('options', function() {
|
| DEFAULT: 1
|
| };
|
|
|
| - //
|
| - // BrowserOptions class
|
| - // Encapsulated handling of browser options page.
|
| - //
|
| + /**
|
| + * Encapsulated handling of browser options page.
|
| + * @constructor
|
| + * @extends {cr.ui.pageManager.Page}
|
| + */
|
| function BrowserOptions() {
|
| Page.call(this, 'settings', loadTimeData.getString('settingsTitle'),
|
| 'settings');
|
| @@ -1428,16 +1429,25 @@ cr.define('options', function() {
|
| ManageProfileOverlay.showDeleteDialog(this.getCurrentProfile_());
|
| },
|
|
|
| + /**
|
| + * @param {boolean} enabled
|
| + */
|
| setNativeThemeButtonEnabled_: function(enabled) {
|
| var button = $('themes-native-button');
|
| if (button)
|
| button.disabled = !enabled;
|
| },
|
|
|
| + /**
|
| + * @param {boolean} enabled
|
| + */
|
| setThemesResetButtonEnabled_: function(enabled) {
|
| $('themes-reset').disabled = !enabled;
|
| },
|
|
|
| + /**
|
| + * @param {boolean} managed
|
| + */
|
| setAccountPictureManaged_: function(managed) {
|
| var picture = $('account-picture');
|
| if (managed || UIAccountTweaks.loggedInAsGuest()) {
|
| @@ -1469,6 +1479,9 @@ cr.define('options', function() {
|
| }
|
| },
|
|
|
| + /**
|
| + * @param {boolean} managed
|
| + */
|
| setWallpaperManaged_: function(managed) {
|
| var button = $('set-wallpaper');
|
| button.disabled = !!managed;
|
| @@ -1913,7 +1926,7 @@ cr.define('options', function() {
|
| };
|
|
|
| //Forward public APIs to private implementations.
|
| - [
|
| + cr.makePublic(BrowserOptions, [
|
| 'addBluetoothDevice',
|
| 'deleteCurrentProfile',
|
| 'enableCertificateButton',
|
| @@ -1960,12 +1973,7 @@ cr.define('options', function() {
|
| 'updateSearchEngines',
|
| 'updateStartupPages',
|
| 'updateSyncState',
|
| - ].forEach(function(name) {
|
| - BrowserOptions[name] = function() {
|
| - var instance = BrowserOptions.getInstance();
|
| - return instance[name + '_'].apply(instance, arguments);
|
| - };
|
| - });
|
| + ]);
|
|
|
| if (cr.isChromeOS) {
|
| /**
|
|
|