1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 2 // Use of this source code is governed by a BSD-style license that can be 3 // found in the LICENSE file. 4 5 if (loadTimeData.getBoolean('newContentSettings')) { 6 7 cr.define('options', function() { 8 /** @const */ var OptionsPage = options.OptionsPage; 9 10 ////////////////////////////////////////////////////////////////////////////// 11 // ContentSettings class: 12 13 /** 14 * Encapsulated handling of content settings page. 15 * @constructor 16 */ 17 function ContentSettings() { 18 this.activeNavTab = null; 19 OptionsPage.call(this, 'content', 20 loadTimeData.getString('contentSettingsPageTabTitle'), 21 'content-settings-page2'); 22 } 23 24 cr.addSingletonGetter(ContentSettings); 25 26 ContentSettings.prototype = { 27 __proto__: OptionsPage.prototype, 28 29 initializePage: function() { 30 OptionsPage.prototype.initializePage.call(this); 31 32 $('content-settings-overlay-confirm2').onclick = 33 OptionsPage.closeOverlay.bind(OptionsPage); 34 }, 35 }; 36 37 ContentSettings.updateHandlersEnabledRadios = function(enabled) { 38 // Not implemented. 39 }; 40 41 /** 42 * Sets the values for all the content settings radios. 43 * @param {Object} dict A mapping from radio groups to the checked value for 44 * that group. 45 */ 46 ContentSettings.setContentFilterSettingsValue = function(dict) { 47 // Not implemented. 48 }; 49 50 /** 51 * Initializes an exceptions list. 52 * @param {string} type The content type that we are setting exceptions for. 53 * @param {Array} list An array of pairs, where the first element of each pair 54 * is the filter string, and the second is the setting (allow/block). 55 */ 56 ContentSettings.setExceptions = function(type, list) { 57 // Not implemented. 58 }; 59 60 ContentSettings.setHandlers = function(list) { 61 // Not implemented. 62 }; 63 64 ContentSettings.setIgnoredHandlers = function(list) { 65 // Not implemented. 66 }; 67 68 ContentSettings.setOTRExceptions = function(type, list) { 69 // Not implemented. 70 }; 71 72 /** 73 * Enables the Pepper Flash camera and microphone settings. 74 * Please note that whether the settings are actually showed or not is also 75 * affected by the style class pepper-flash-settings. 76 */ 77 ContentSettings.enablePepperFlashCameraMicSettings = function() { 78 // Not implemented. 79 } 80 81 // Export 82 return { 83 ContentSettings: ContentSettings 84 }; 85 86 }); 87 88 } 89