Chromium Code Reviews| Index: chrome/browser/resources/options/content_settings.js |
| diff --git a/chrome/browser/resources/options/content_settings.js b/chrome/browser/resources/options/content_settings.js |
| index 8925de8c140e1726f1d89744c2f147fa6b0eecf6..c8b4f5c1a39e2fb485a16fda5b18d128bff11bb1 100644 |
| --- a/chrome/browser/resources/options/content_settings.js |
| +++ b/chrome/browser/resources/options/content_settings.js |
| @@ -45,6 +45,12 @@ cr.define('options', function() { |
| }; |
| } |
| + var manageHandlersButton = |
| + this.pageDiv.querySelector('#manage-handlers-button'); |
| + manageHandlersButton.onclick = function(event) { |
| + OptionsPage.navigateToPage('handlers'); |
| + }; |
| + |
| // Cookies filter page --------------------------------------------------- |
| $('block-third-party-cookies').onclick = function(event) { |
| chrome.send('setAllowThirdPartyCookies', |
| @@ -61,6 +67,15 @@ cr.define('options', function() { |
| }, |
| }; |
| + ContentSettings.updateHandlersEnabledRadios = function(enabled) { |
|
Evan Stade
2011/05/20 22:01:28
var selector = '#handlers-section input[type=radio
koz (OOO until 15th September)
2011/05/20 22:19:56
Done.
|
| + var allow = '#handlers-section input[type=radio][value=allow]'; |
| + var block = '#handlers-section input[type=radio][value=block]'; |
| + if (enabled) |
| + document.querySelector(allow).checked = true; |
| + else |
| + document.querySelector(block).checked = true; |
| + }; |
| + |
| /** |
| * Sets the values for all the content settings radios. |
| * @param {Object} dict A mapping from radio groups to the checked value for |
| @@ -90,10 +105,13 @@ cr.define('options', function() { |
| var exceptionsList = |
| document.querySelector('div[contentType=' + type + ']' + |
| ' list[mode=normal]'); |
| - |
| exceptionsList.setExceptions(list); |
| }; |
| + ContentSettings.setHandlers = function(list) { |
| + $('handlers-list').setHandlers(list); |
| + }; |
| + |
| ContentSettings.setOTRExceptions = function(type, list) { |
| var exceptionsList = |
| document.querySelector('div[contentType=' + type + ']' + |