Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 8b72bbc

Browse files
authored
remove FrameTiming named constructor (#20380)
1 parent 9bc3fe9 commit 8b72bbc

File tree

2 files changed

+0
-48
lines changed

2 files changed

+0
-48
lines changed

lib/ui/window.dart

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -117,30 +117,6 @@ class FrameTiming {
117117
FrameTiming._(List<int> timestamps)
118118
: assert(timestamps.length == FramePhase.values.length), _timestamps = timestamps;
119119

120-
/// Construct [FrameTiming] with given timestamp in micrseconds.
121-
///
122-
/// This constructor is used for unit test only. Real [FrameTiming]s should
123-
/// be retrieved from [Window.onReportTimings].
124-
///
125-
/// TODO(CareF): This is part of #20229. Remove back to default constructor
126-
/// after #20229 lands and corresponding framwork PRs land.
127-
factory FrameTiming.fromTimeStamps({
128-
int? vsyncStart,
129-
required int buildStart,
130-
required int buildFinish,
131-
required int rasterStart,
132-
required int rasterFinish
133-
}) {
134-
return FrameTiming._(<int>[
135-
// This is for temporarily backward compatiblilty.
136-
vsyncStart ?? buildStart,
137-
buildStart,
138-
buildFinish,
139-
rasterStart,
140-
rasterFinish
141-
]);
142-
}
143-
144120
/// This is a raw timestamp in microseconds from some epoch. The epoch in all
145121
/// [FrameTiming] is the same, but it may not match [DateTime]'s epoch.
146122
int timestampInMicroseconds(FramePhase phase) => _timestamps[phase.index];

lib/web_ui/lib/src/ui/window.dart

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -1070,30 +1070,6 @@ class FrameTiming {
10701070
FrameTiming._(List<int> timestamps)
10711071
: assert(timestamps.length == FramePhase.values.length), _timestamps = timestamps;
10721072

1073-
/// Construct [FrameTiming] with given timestamp in micrseconds.
1074-
///
1075-
/// This constructor is used for unit test only. Real [FrameTiming]s should
1076-
/// be retrieved from [Window.onReportTimings].
1077-
///
1078-
/// TODO(CareF): This is part of #20229. Remove back to default constructor
1079-
/// after #20229 lands and corresponding framwork PRs land.
1080-
factory FrameTiming.fromTimeStamps({
1081-
int? vsyncStart,
1082-
required int buildStart,
1083-
required int buildFinish,
1084-
required int rasterStart,
1085-
required int rasterFinish
1086-
}) {
1087-
return FrameTiming._(<int>[
1088-
// This is for temporarily backward compatiblilty.
1089-
vsyncStart ?? buildStart,
1090-
buildStart,
1091-
buildFinish,
1092-
rasterStart,
1093-
rasterFinish
1094-
]);
1095-
}
1096-
10971073
/// This is a raw timestamp in microseconds from some epoch. The epoch in all
10981074
/// [FrameTiming] is the same, but it may not match [DateTime]'s epoch.
10991075
int timestampInMicroseconds(FramePhase phase) => _timestamps[phase.index];

0 commit comments

Comments
 (0)