Skip to content
Permalink
Browse files
Web Inspector: Timelines Tab: Screenshots: enable by default
https://bugs.webkit.org/show_bug.cgi?id=241144

Reviewed by Patrick Angle.

* Source/WebInspectorUI/Localizations/en.lproj/localizedStrings.js:
* Source/WebInspectorUI/UserInterface/Base/Setting.js:
* Source/WebInspectorUI/UserInterface/Models/ScreenshotsInstrument.js:
(WI.ScreenshotsInstrument.supported):
* Source/WebInspectorUI/UserInterface/Views/SettingsTabContentView.js:
(WI.SettingsTabContentView.prototype._createExperimentalSettingsView):

Canonical link: https://commits.webkit.org/251169@main
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@295074 268f45cc-cd09-0410-ab3c-d52691b4dbfc
  • Loading branch information
dcrousso committed Jun 1, 2022
1 parent b443fbf commit b36992d61e862eeab2e3434dfe09d603b8bed587
Show file tree
Hide file tree
Showing 4 changed files with 1 addition and 9 deletions.
@@ -1387,7 +1387,6 @@ localizedStrings["Show Elements"] = "Show Elements";
localizedStrings["Show Path"] = "Show Path";
localizedStrings["Show Remaining (%d)"] = "Show Remaining (%d)";
localizedStrings["Show Scope Chain on pause"] = "Show Scope Chain on pause";
localizedStrings["Show Screenshots"] = "Show Screenshots";
localizedStrings["Show all actions"] = "Show all actions";
localizedStrings["Show all resources"] = "Show all resources";
localizedStrings["Show changes only for selected node"] = "Show changes only for selected node";
@@ -1593,7 +1592,6 @@ localizedStrings["Timeline Recording %d"] = "Timeline Recording %d";
localizedStrings["Timeline Recording Import Error: %s"] = "Timeline Recording Import Error: %s";
/* Name of Timelines Tab */
localizedStrings["Timelines Tab Name"] = "Timelines";
localizedStrings["Timelines:"] = "Timelines:";
/* Text indicating that the local override will block the network activity with an timeout error. */
localizedStrings["Timeout @ Local Override Type"] = "Timeout";
localizedStrings["Timer %d Fired"] = "Timer %d Fired";
@@ -233,7 +233,6 @@ WI.settings = {
experimentalAllowInspectingInspector: new WI.Setting("experimental-allow-inspecting-inspector", false),
experimentalCSSCompletionFuzzyMatching: new WI.Setting("experimental-css-completion-fuzzy-matching", true),
experimentalCSSSortPropertyNameAutocompletionByUsage: new WI.Setting("experimental-css-sort-property-name-autocompletion-by-usage", false),
experimentalShowScreenshotsTimeline: new WI.Setting("experimental-show-screenshots-timeline", false),

// Protocol
protocolLogAsText: new WI.Setting("protocol-log-as-text", false),
@@ -37,7 +37,7 @@ WI.ScreenshotsInstrument = class ScreenshotsInstrument extends WI.Instrument
static supported()
{
// COMPATIBILITY (iOS 15.4): Timeline.Instrument.Screenshot did not exist yet.
return InspectorBackend.Enum.Timeline.Instrument.Screenshot && (WI.settings.experimentalShowScreenshotsTimeline.value || window.InspectorTest);
return InspectorBackend.Enum.Timeline.Instrument.Screenshot;
}

// Protected
@@ -401,9 +401,6 @@ WI.SettingsTabContentView = class SettingsTabContentView extends WI.TabContentVi
diagnosticsGroup.addSetting(WI.settings.experimentalAllowInspectingInspector, WI.UIString("Allow Inspecting Web Inspector", "Allow Inspecting Web Inspector @ Experimental Settings", "Label for setting that allows the user to inspect the Web Inspector user interface."));
experimentalSettingsView.addSeparator();

let timelinesGroup = experimentalSettingsView.addGroup(WI.UIString("Timelines:"));
timelinesGroup.addSetting(WI.settings.experimentalShowScreenshotsTimeline, WI.UIString("Show Screenshots"));

let reloadInspectorButton = document.createElement("button");
reloadInspectorButton.textContent = WI.UIString("Reload Web Inspector");
reloadInspectorButton.addEventListener("click", (event) => {
@@ -420,8 +417,6 @@ WI.SettingsTabContentView = class SettingsTabContentView extends WI.TabContentVi
}, reloadInspectorContainerElement);
}

listenForChange(WI.settings.experimentalShowScreenshotsTimeline);

if (hasCSSDomain) {
listenForChange(WI.settings.experimentalEnableStylesJumpToEffective);
listenForChange(WI.settings.experimentalEnableStylesJumpToVariableDeclaration);

0 comments on commit b36992d

Please sign in to comment.