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

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: remove in_unit_test_ 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 0723c07050b9ec05e9e248a520e1acd3f72f9be1..bcd58ce023565042a677d976e6d643fa9f2334be 100644
--- a/chrome/browser/resources/options/content_settings.js
+++ b/chrome/browser/resources/options/content_settings.js
@@ -45,6 +45,14 @@ cr.define('options', function() {
};
}
+ var manageHandlersButton =
+ this.pageDiv.querySelector('#manage-handlers-button');
+ if (manageHandlersButton) {
+ manageHandlersButton.onclick = function(event) {
+ OptionsPage.navigateToPage('handlers');
+ };
+ }
+
// Cookies filter page ---------------------------------------------------
$('block-third-party-cookies').onclick = function(event) {
chrome.send('setAllowThirdPartyCookies',
@@ -61,6 +69,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;
+ };
+
/**
* Sets the values for all the content settings radios.
* @param {Object} dict A mapping from radio groups to the checked value for
@@ -90,10 +104,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 + ']' +
« no previous file with comments | « chrome/browser/resources/options/content_settings.html ('k') | chrome/browser/resources/options/content_settings_ui.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698