Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Replace ListView with ListView.builder for LicensesPage #102692

Merged

Conversation

Maistho
Copy link
Contributor

@Maistho Maistho commented Apr 27, 2022

For apps with a large amount of dependencies, LicensesPage can become slow on some older devices. Using ListView.builder() instead of ListView() reduces the likelihood of that.

@flutter-dashboard flutter-dashboard bot added f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels. labels Apr 27, 2022
@flutter-dashboard
Copy link

It looks like this pull request may not have tests. Please make sure to add tests before merging. If you need an exemption to this rule, contact Hixie on the #hackers channel in Chat (don't just cc him here, he won't see it! He's on Discord!).

If you are not sure if you need tests, consider this rule of thumb: the purpose of a test is to make sure someone doesn't accidentally revert the fix. Ask yourself, is there anything in your PR that you feel it is important we not accidentally revert back to how it was before your fix?

Reviewers: Read the Tree Hygiene page and make sure this patch meets those guidelines before LGTMing.

@Maistho
Copy link
Contributor Author

Maistho commented Apr 27, 2022

I think that the existing tests should cover this change well enough.

It might be possible to create a test that checks that the scrolling performance is still good for when the list has a lot of packages, but experience leads me to believe that such a test could be potentially flaky, and probably more effort to implement than it's worth.

@Maistho Maistho force-pushed the licenses-page-listview-builder branch 3 times, most recently from 5c13a8f to 37c924e Compare April 27, 2022 22:29
@cedvdb
Copy link
Contributor

cedvdb commented Apr 27, 2022

I think you have to ping someone for this to be test exempt. I've seen it in a couple PR.

@Maistho
Copy link
Contributor Author

Maistho commented Apr 27, 2022 via email

@Hixie
Copy link
Contributor

Hixie commented Apr 28, 2022

test-exempt: code refactor with no semantic change

cc @gspencergoog for review

Copy link
Member

@goderbauer goderbauer left a comment

Choose a reason for hiding this comment

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

Overall this looks good with just one tiny fix.

packages/flutter/lib/src/material/about.dart Outdated Show resolved Hide resolved
@Maistho Maistho force-pushed the licenses-page-listview-builder branch from 37c924e to accc69e Compare May 7, 2022 03:14
For apps with a large amount of dependencies, LicensesPage can become
slow on some older devices. Using ListView.builder() instead of
ListView() reduces the likelihood of that.
@Maistho Maistho force-pushed the licenses-page-listview-builder branch from accc69e to 78bbcfd Compare May 7, 2022 03:16
Copy link
Member

@goderbauer goderbauer left a comment

Choose a reason for hiding this comment

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

LGTM

Copy link
Contributor

@gspencergoog gspencergoog left a comment

Choose a reason for hiding this comment

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

32384589-a60f0e74-c078-11e7-9bc1-e5b5287aea9d

@fluttergithubbot fluttergithubbot merged commit 9511638 into flutter:master May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
ditman added a commit to ditman/flutter-packages that referenced this pull request May 9, 2022
Roll Flutter from b305eb633780 to 4c573207acc3 (33 revisions)

flutter/flutter@b305eb6...4c57320

2022-05-09 engine-flutter-autoroll@skia.org Roll Flutter Engine from 71b9adccfb63 to 6248a5a9ae28 (1 revision) (flutter/flutter#103350)
2022-05-09 engine-flutter-autoroll@skia.org Roll Flutter Engine from 3af7fb24d4dd to 71b9adccfb63 (1 revision) (flutter/flutter#103347)
2022-05-09 jesus_sguerrero@hotmail.com [flutter_tools] stringArg refactor (flutter/flutter#103231)
2022-05-09 maistho@gmail.com Replace ListView with ListView.builder for LicensesPage (flutter/flutter#102692)
2022-05-09 gspencergoog@users.noreply.github.com Adds `menuBarMenuLabel`, and removes unneeded key localizations (flutter/flutter#102100)
2022-05-09 engine-flutter-autoroll@skia.org Roll Plugins from 49b06b3 to c5c319a (15 revisions) (flutter/flutter#103345)
2022-05-09 engine-flutter-autoroll@skia.org Roll Engine from e7c44a582c58 to 3af7fb24d4dd (1 revision) (flutter/flutter#103334)
2022-05-09 engine-flutter-autoroll@skia.org Roll Engine from c02712fe1160 to e7c44a582c58 (1 revision) (flutter/flutter#103333)
2022-05-09 engine-flutter-autoroll@skia.org Roll Engine from 6efd8f00dcc6 to c02712fe1160 (1 revision) (flutter/flutter#103327)
2022-05-09 tessertaha@gmail.com `CupertinoTabScaffold`/`CupertinoTabController`: Add interactive examples (flutter/flutter#103196)
2022-05-09 engine-flutter-autoroll@skia.org Roll Engine from c930e64a13bc to 6efd8f00dcc6 (1 revision) (flutter/flutter#103323)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from d0e6e14d27cc to c930e64a13bc (2 revisions) (flutter/flutter#103308)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from fffb3eb58e7d to d0e6e14d27cc (1 revision) (flutter/flutter#103307)
2022-05-08 danny@tuppeny.com Use consistent date instead of DateTime.now() in evaluation tests (flutter/flutter#103269)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from 259ccadd8203 to fffb3eb58e7d (1 revision) (flutter/flutter#103298)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from 0b84783081a7 to 259ccadd8203 (1 revision) (flutter/flutter#103293)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from 19d5f037f221 to 0b84783081a7 (1 revision) (flutter/flutter#103291)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from 2d1f34cbdde2 to 19d5f037f221 (1 revision) (flutter/flutter#103289)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from b89e093d887f to 2d1f34cbdde2 (1 revision) (flutter/flutter#103287)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from aa80520b7fc9 to b89e093d887f (1 revision) (flutter/flutter#103286)
2022-05-08 engine-flutter-autoroll@skia.org Roll Engine from 4c05cb763866 to aa80520b7fc9 (1 revision) (flutter/flutter#103283)
2022-05-07 engine-flutter-autoroll@skia.org Roll Engine from 235d951ccfbd to 4c05cb763866 (1 revision) (flutter/flutter#103279)
2022-05-07 engine-flutter-autoroll@skia.org Roll Engine from 24466845e7a9 to 235d951ccfbd (4 revisions) (flutter/flutter#103276)
2022-05-07 engine-flutter-autoroll@skia.org Roll Engine from 2d2f8629cdb2 to 24466845e7a9 (1 revision) (flutter/flutter#103274)
2022-05-07 engine-flutter-autoroll@skia.org Roll Engine from 4a358030cb07 to 2d2f8629cdb2 (1 revision) (flutter/flutter#103273)
2022-05-07 fujino@google.com [flutter_tools] add --uninstall-first flag and pipe it through to ios-deploy (flutter/flutter#102948)
2022-05-07 xubaolin@oppo.com Fix a `_WrappedScrollBehavior.shouldNotify` bug (flutter/flutter#103267)
2022-05-07 magder@google.com Remove custom `unawaited`, prefer `dart:async` version (flutter/flutter#103212)
2022-05-07 36861262+QuncCccccc@users.noreply.github.com Added clipBehavior on TabBarView (flutter/flutter#103166)
2022-05-07 leroux_bruno@yahoo.fr Fix empty Stack with infinite constraints throws (flutter/flutter#102642)
2022-05-07 42252197+egramond@users.noreply.github.com Updating the Slider Widget to allow up and down arrow keys to navigate out of the slider when in directional NavigationMode. (flutter/flutter#103149)
2022-05-07 tessertaha@gmail.com Fix `DropdownButton` menu clip (flutter/flutter#102970)
2022-05-07 engine-flutter-autoroll@skia.org Roll Engine from 094cb30943a5 to 4a358030cb07 (1 revision) (flutter/flutter#103260)

If this roll has caused a breakage, revert this CL and stop the roller
using the controls here:
https://autoroll.skia.org/r/flutter-packages
Please CC stuartmorgan@google.com on the revert to ensure that a human
is aware of the problem.

To file a bug in Packages: https://github.com/flutter/flutter/issues/new/choose

To report a problem with the AutoRoller itself, please file a bug:
https://bugs.chromium.org/p/skia/issues/entry?template=Autoroller+Bug

Documentation for the AutoRoller is here:
...
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request May 9, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request May 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

6 participants