Skip to content
Open
Changes from all 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
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,19 @@ class _RebuildStatsViewState extends State<RebuildStatsView>

@override
Widget build(BuildContext context) {
final isProfileBuild =
serviceConnection.serviceManager.connectedApp?.isProfileBuildNow ??
false;
if (isProfileBuild) {
return const Center(
child: Text(
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please add test for profile mode, thank you!

'Rebuild information is not available for this frame.\n'
'Widget rebuild counts are only available when running '
'an app in debug-mode.',
textAlign: TextAlign.center,
),
);
}
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Expand Down Expand Up @@ -138,7 +151,7 @@ class _RebuildStatsViewState extends State<RebuildStatsView>
if (metrics.isEmpty) {
return const Center(
child: Text('Interact with the app to trigger rebuilds.'),
); // No data to display but there should be data soon.
);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this comment needs to be removed.

}
return RebuildTable(
key: const Key('Rebuild Table'),
Expand Down