Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion front_end/core/host/UserMetrics.ts
Original file line number Diff line number Diff line change
Expand Up @@ -985,10 +985,11 @@ export enum DevtoolsExperiments {
'timeline-alternative-navigation' = 104,
// 106 was historically used [https://chromium-review.googlesource.com/c/devtools/devtools-frontend/+/6230097]
// next experiment should be 107
'timeline-frames' = 108,
/* eslint-enable @typescript-eslint/naming-convention */

// Increment this when new experiments are added.
MAX_VALUE = 106,
MAX_VALUE = 108,
}

// Update DevToolsIssuesPanelIssueExpanded from tools/metrics/histograms/enums.xml if new enum is added.
Expand Down
1 change: 1 addition & 0 deletions front_end/core/root/Runtime.ts
Original file line number Diff line number Diff line change
Expand Up @@ -332,6 +332,7 @@ export const enum ExperimentName {
TIMELINE_DEBUG_MODE = 'timeline-debug-mode',
TIMELINE_ENHANCED_TRACES = 'timeline-enhanced-traces',
TIMELINE_COMPILED_SOURCES = 'timeline-compiled-sources',
TIMELINE_FRAMES = 'timeline-frames',
TIMELINE_EXPERIMENTAL_INSIGHTS = 'timeline-experimental-insights',
TIMELINE_DIM_UNRELATED_EVENTS = 'timeline-dim-unrelated-events',
TIMELINE_ALTERNATIVE_NAVIGATION = 'timeline-alternative-navigation',
Expand Down
2 changes: 2 additions & 0 deletions front_end/entrypoints/main/MainImpl.ts
Original file line number Diff line number Diff line change
Expand Up @@ -301,6 +301,8 @@ export class MainImpl {
Root.Runtime.experiments.register(
Root.Runtime.ExperimentName.TIMELINE_DEBUG_MODE,
'Performance panel: Enable debug mode (trace event details, etc)', true);
Root.Runtime.experiments.register(
Root.Runtime.ExperimentName.TIMELINE_FRAMES, 'Performance panel: Enable frames track', true);

// Debugging
Root.Runtime.experiments.register('instrumentation-breakpoints', 'Enable instrumentation breakpoints', true);
Expand Down
9 changes: 1 addition & 8 deletions front_end/panels/timeline/TimelineFlameChartDataProvider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -106,8 +106,6 @@ const i18nString = i18n.i18n.getLocalizedString.bind(undefined, str_);

export class TimelineFlameChartDataProvider extends Common.ObjectWrapper.ObjectWrapper<EventTypes> implements
PerfUI.FlameChart.FlameChartDataProvider {
private isReactNative = false;

private droppedFramePatternCanvas: HTMLCanvasElement;
private partialFramePatternCanvas: HTMLCanvasElement;
private timelineDataInternal: PerfUI.FlameChart.FlameChartTimelineData|null = null;
Expand Down Expand Up @@ -145,11 +143,6 @@ export class TimelineFlameChartDataProvider extends Common.ObjectWrapper.ObjectW
constructor() {
super();

// [RN] Used to scope down available features for React Native targets
this.isReactNative = Root.Runtime.experiments.isEnabled(
Root.Runtime.ExperimentName.REACT_NATIVE_SPECIFIC_UI,
);

this.reset();

this.droppedFramePatternCanvas = document.createElement('canvas');
Expand Down Expand Up @@ -615,7 +608,7 @@ export class TimelineFlameChartDataProvider extends Common.ObjectWrapper.ObjectW
// In CPU Profiles the trace data will not have frames nor
// screenshots, so we can keep this call as it will be a no-op in
// these cases.
if (!this.isReactNative) {
if (Root.Runtime.experiments.isEnabled(Root.Runtime.ExperimentName.TIMELINE_FRAMES)) {
this.#appendFramesAndScreenshotsTrack();
}

Expand Down
1 change: 1 addition & 0 deletions front_end/testing/EnvironmentHelpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,7 @@ const REGISTERED_EXPERIMENTS = [
Root.Runtime.ExperimentName.TIMELINE_EXPERIMENTAL_INSIGHTS,
Root.Runtime.ExperimentName.TIMELINE_DIM_UNRELATED_EVENTS,
Root.Runtime.ExperimentName.TIMELINE_ALTERNATIVE_NAVIGATION,
Root.Runtime.ExperimentName.TIMELINE_FRAMES,
Root.Runtime.ExperimentName.REACT_NATIVE_SPECIFIC_UI,
Root.Runtime.ExperimentName.NOT_REACT_NATIVE_SPECIFIC_UI,
];
Expand Down
1 change: 1 addition & 0 deletions front_end/ui/visual_logging/KnownContextValues.ts
Original file line number Diff line number Diff line change
Expand Up @@ -3495,6 +3495,7 @@ export const knownContextValues = new Set([
'time',
'timeline',
'timeline-alternative-navigation',
'timeline-frames',
'timeline-capture-layers-and-pictures',
'timeline-capture-selector-stats',
'timeline-compiled-sources',
Expand Down
Loading