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 4698e563d59078a3f15638fc725e7d61109d917b..2cad57c18e0e449711bd756ad22f5ad0317caa2b 100644 |
--- a/chrome/browser/resources/options/browser_options.js |
+++ b/chrome/browser/resources/options/browser_options.js |
@@ -110,7 +110,12 @@ cr.define('options', function() { |
// On Startup section. |
Preferences.getInstance().addEventListener('session.restore_on_startup', |
- this.onRestoreOnStartupChanged_.bind(this)); |
+ this.onRestoreOnStartupChanged_.bind(this)); |
+ Preferences.getInstance().addEventListener( |
+ 'session.urls_to_restore_on_startup', |
+ function(event) { |
+ $('startup-set-pages').disabled = event.value.disabled; |
+ }); |
$('startup-set-pages').onclick = function() { |
OptionsPage.navigateToPage('startup'); |
@@ -467,12 +472,8 @@ cr.define('options', function() { |
* @private |
*/ |
onRestoreOnStartupChanged_: function(event) { |
- /** @const */ var showPagesValue = Number($('startup-show-pages').value); |
/** @const */ var showHomePageValue = 0; |
- $('startup-set-pages').disabled = event.value.disabled && |
- event.value.value != showPagesValue; |
- |
if (event.value.value == showHomePageValue) { |
// If the user previously selected "Show the homepage", the |
// preference will already be migrated to "Open a specific page". So |