Skip to content
Permalink
Browse files
Web Inspector: Audit: remove experimental setting
https://bugs.webkit.org/show_bug.cgi?id=193743
<rdar://problem/28234022>

Reviewed by Joseph Pecoraro.

* UserInterface/Base/Setting.js:
(WI.Setting):
(WI.Setting.localStorageKey): Added.
(WI.Setting.migrateValue):
Drive-by: add the localStorage key prefix to the key passed into `WI.Setting.migrateValue`.

* UserInterface/Base/Main.js:
(WI.loaded):

* UserInterface/Views/AuditTabContentView.js:
(WI.AuditTabContentView.isTabAllowed):

* UserInterface/Views/SettingsTabContentView.js:
(WI.SettingsTabContentView.prototype._createExperimentalSettingsView):

* Localizations/en.lproj/localizedStrings.js:


Canonical link: https://commits.webkit.org/208339@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@240502 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
dcrousso committed Jan 25, 2019
1 parent 9dd4fd8 commit e1a1c514794a249255a92576a6707c53be8ee443
@@ -1,3 +1,28 @@
2019-01-25 Devin Rousso <drousso@apple.com>

Web Inspector: Audit: remove experimental setting
https://bugs.webkit.org/show_bug.cgi?id=193743
<rdar://problem/28234022>

Reviewed by Joseph Pecoraro.

* UserInterface/Base/Setting.js:
(WI.Setting):
(WI.Setting.localStorageKey): Added.
(WI.Setting.migrateValue):
Drive-by: add the localStorage key prefix to the key passed into `WI.Setting.migrateValue`.

* UserInterface/Base/Main.js:
(WI.loaded):

* UserInterface/Views/AuditTabContentView.js:
(WI.AuditTabContentView.isTabAllowed):

* UserInterface/Views/SettingsTabContentView.js:
(WI.SettingsTabContentView.prototype._createExperimentalSettingsView):

* Localizations/en.lproj/localizedStrings.js:

2019-01-25 Devin Rousso <drousso@apple.com>

Web Inspector: show uncaught exception view for unhandled promise rejections
@@ -133,7 +133,6 @@ localizedStrings["Attributes"] = "Attributes";
localizedStrings["Audit"] = "Audit";
localizedStrings["Audit Error: %s"] = "Audit Error: %s";
localizedStrings["Audit Warning: %s"] = "Audit Warning: %s";
localizedStrings["Audit:"] = "Audit:";
localizedStrings["Audits"] = "Audits";
localizedStrings["Author Stylesheet"] = "Author Stylesheet";
localizedStrings["Auto Increment"] = "Auto Increment";
@@ -361,7 +360,6 @@ localizedStrings["Element is the root element"] = "Element is the root element";
localizedStrings["Element may overlap another compositing element"] = "Element may overlap another compositing element";
localizedStrings["Element overlaps other compositing element"] = "Element overlaps other compositing element";
localizedStrings["Elements"] = "Elements";
localizedStrings["Enable Audit Tab"] = "Enable Audit Tab";
localizedStrings["Enable Breakpoint"] = "Enable Breakpoint";
localizedStrings["Enable Breakpoints"] = "Enable Breakpoints";
localizedStrings["Enable Computed Style Cascades"] = "Enable Computed Style Cascades";
@@ -148,6 +148,7 @@ WI.loaded = function()
WI.TimelineTabContentView.Type,
WI.StorageTabContentView.Type,
WI.CanvasTabContentView.Type,
WI.AuditTabContentView.Type,
WI.ConsoleTabContentView.Type,
]);
this._selectedTabIndexSetting = new WI.Setting("selected-tab-index", 0);
@@ -49,7 +49,7 @@ WI.AuditTabContentView = class AuditTabContentView extends WI.ContentBrowserTabC

static isTabAllowed()
{
return !!window.RuntimeAgent && WI.settings.experimentalEnableAuditTab.value;
return WI.sharedApp.debuggableType === WI.DebuggableType.Web;
}

// Public
@@ -264,9 +264,6 @@ WI.SettingsTabContentView = class SettingsTabContentView extends WI.TabContentVi
experimentalSettingsView.addSeparator();
}

experimentalSettingsView.addSetting(WI.UIString("Audit:"), WI.settings.experimentalEnableAuditTab, WI.UIString("Enable Audit Tab"));
experimentalSettingsView.addSeparator();

experimentalSettingsView.addSetting(WI.UIString("User Interface:"), WI.settings.experimentalEnableNewTabBar, WI.UIString("Enable New Tab Bar"));
experimentalSettingsView.addSeparator();

@@ -277,8 +274,6 @@ WI.SettingsTabContentView = class SettingsTabContentView extends WI.TabContentVi
let newTabs = WI._openTabsSetting.value.slice();
if (!initialValues.get(WI.settings.experimentalEnableLayersTab) && window.LayerTreeAgent && WI.settings.experimentalEnableLayersTab.value)
newTabs.push(WI.LayersTabContentView.Type);
if (!initialValues.get(WI.settings.experimentalEnableAuditTab) && WI.settings.experimentalEnableAuditTab.value)
newTabs.push(WI.AuditTabContentView.Type);
WI._openTabsSetting.value = newTabs;

InspectorFrontendHost.reopen();
@@ -296,7 +291,6 @@ WI.SettingsTabContentView = class SettingsTabContentView extends WI.TabContentVi

listenForChange(WI.settings.experimentalEnableComputedStyleCascades);
listenForChange(WI.settings.experimentalEnableLayersTab);
listenForChange(WI.settings.experimentalEnableAuditTab);
listenForChange(WI.settings.experimentalEnableNewTabBar);

this.addSettingsView(experimentalSettingsView);

0 comments on commit e1a1c51

Please sign in to comment.