| OLD | NEW |
| 1 /* | 1 /* |
| 2 * Copyright (C) 2013 Google Inc. All rights reserved. | 2 * Copyright (C) 2013 Google Inc. All rights reserved. |
| 3 * | 3 * |
| 4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
| 5 * modification, are permitted provided that the following conditions are | 5 * modification, are permitted provided that the following conditions are |
| 6 * met: | 6 * met: |
| 7 * | 7 * |
| 8 * * Redistributions of source code must retain the above copyright | 8 * * Redistributions of source code must retain the above copyright |
| 9 * notice, this list of conditions and the following disclaimer. | 9 * notice, this list of conditions and the following disclaimer. |
| 10 * * Redistributions in binary form must reproduce the above | 10 * * Redistributions in binary form must reproduce the above |
| (...skipping 186 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 197 * @param {!Runtime.Extension} extension | 197 * @param {!Runtime.Extension} extension |
| 198 */ | 198 */ |
| 199 _addSetting: function(extension) | 199 _addSetting: function(extension) |
| 200 { | 200 { |
| 201 if (!WebInspector.GenericSettingsTab.isSettingVisible(extension)) | 201 if (!WebInspector.GenericSettingsTab.isSettingVisible(extension)) |
| 202 return; | 202 return; |
| 203 var descriptor = extension.descriptor(); | 203 var descriptor = extension.descriptor(); |
| 204 var sectionName = descriptor["category"]; | 204 var sectionName = descriptor["category"]; |
| 205 var settingName = descriptor["settingName"]; | 205 var settingName = descriptor["settingName"]; |
| 206 var setting = WebInspector.moduleSetting(settingName); | 206 var setting = WebInspector.moduleSetting(settingName); |
| 207 var uiTitle = WebInspector.UIString(extension.title(WebInspector.platfor
m())); | 207 var uiTitle = WebInspector.UIString(extension.title()); |
| 208 | 208 |
| 209 var sectionElement = this._sectionElement(sectionName); | 209 var sectionElement = this._sectionElement(sectionName); |
| 210 var settingControl; | 210 var settingControl; |
| 211 | 211 |
| 212 switch (descriptor["settingType"]) { | 212 switch (descriptor["settingType"]) { |
| 213 case "boolean": | 213 case "boolean": |
| 214 settingControl = WebInspector.SettingsUI.createSettingCheckbox(uiTit
le, setting); | 214 settingControl = WebInspector.SettingsUI.createSettingCheckbox(uiTit
le, setting); |
| 215 break; | 215 break; |
| 216 case "enum": | 216 case "enum": |
| 217 var descriptorOptions = descriptor["options"]; | 217 var descriptorOptions = descriptor["options"]; |
| (...skipping 368 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 586 if (settings && settings.indexOf(setting.name) !== -1) { | 586 if (settings && settings.indexOf(setting.name) !== -1) { |
| 587 InspectorFrontendHost.bringToFront(); | 587 InspectorFrontendHost.bringToFront(); |
| 588 WebInspector._settingsController.showSettingsScreen(extension.de
scriptor()["name"]); | 588 WebInspector._settingsController.showSettingsScreen(extension.de
scriptor()["name"]); |
| 589 success = true; | 589 success = true; |
| 590 } | 590 } |
| 591 } | 591 } |
| 592 } | 592 } |
| 593 } | 593 } |
| 594 | 594 |
| 595 WebInspector._settingsController = new WebInspector.SettingsController(); | 595 WebInspector._settingsController = new WebInspector.SettingsController(); |
| OLD | NEW |