Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(917)

Unified Diff: chrome/browser/resources/options/content_settings.js

Issue 7033018: Handler settings page. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: small nits Created 9 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
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..0196c6bcc18a3a8a47d89090647c58b457b25433 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,12 @@ cr.define('options', function() {
},
};
+ ContentSettings.updateHandlersEnabledRadios = function(enabled) {
+ var selector = '#handlers-section input[type=radio][value=' +
+ (enabled ? 'allow' : 'block') + ']';
+ document.querySelector(selector).checked = true;
tony 2011/05/23 21:42:00 Nit: indent is off
koz (OOO until 15th September) 2011/05/24 08:47:49 Done.
+ };
+
/**
* Sets the values for all the content settings radios.
* @param {Object} dict A mapping from radio groups to the checked value for
@@ -90,10 +102,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 + ']' +

Powered by Google App Engine
This is Rietveld 408576698