Repository navigation
Refactor flutter_view example to not use material - #190377
Conversation
There was a problem hiding this comment.
Code Review
This pull request migrates the flutter_view example from using Material Design (MaterialApp, Scaffold, FloatingActionButton) to a lightweight implementation using WidgetsApp and custom widgets. It also adds iOS SceneDelegate support for the UISceneSession lifecycle. Feedback suggests defining a default textStyle in WidgetsApp to eliminate redundant styling on individual Text widgets, and updating the custom _FloatingActionButton constructor to support super.key.
|
It looks like this pull request may not have tests. Please make sure to add tests or get an explicit test exemption before merging. 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. If you believe this PR qualifies for a test exemption, contact "@test-exemption-reviewer" in the #hackers channel in Discord (don't just cc them here, they won't see it!). The test exemption team is a small volunteer group, so all reviewers should feel empowered to ask for tests, without delegating that responsibility entirely to the test exemption group. |
|
This will also need to be removed from the examples checker, though |
justinmc
left a comment
There was a problem hiding this comment.
LGTM, but as @navaronbracke said I thought you would have to remove this file from the cross import checker. I don't know how CI is passing. Maybe this PR was created before that checker was added?
| } | ||
| } | ||
|
|
||
| class Button extends StatelessWidget { |
There was a problem hiding this comment.
Nit: Maybe make it private so it's clear to readers that it's not part of Flutter.
I've wondered that before. Is it running in CI? |
b667481
b667481 to
94cd9c7
Compare
|
@justinmc pointed out this PR was on a flutter base that did not contain |
| relativePath.startsWith('examples/api/test/widgets') => | ||
| _ApiExampleLibrary(relativePath), | ||
| _ | ||
| when relativePath.startsWith('examples/flutter_view') || |
There was a problem hiding this comment.
Is it necessary to delete flutter_view from here as well?
There was a problem hiding this comment.
No, this is part of the checker itself. I'd just remove it from the exclusion list and leave the rest as is.
There was a problem hiding this comment.
+1, leaving this means the checker will continue to check this directory, which it should do in case we ever accidentally add a cross import back in there.
| } | ||
|
|
||
| class _Button extends StatelessWidget { | ||
| const _Button({super.key, required this.onPressed, required this.icon}); |
There was a problem hiding this comment.
Looks like this is failing CI because key is never used.
justinmc
left a comment
There was a problem hiding this comment.
LGTM but heads up there appear to be unrelated failures.
8bf380c to
a866f59
Compare
This PR refactors the
flutter_viewexample to not usematerial.It also migrates the iOS app to utilize the UIScene lifecycle. Without the migration the app refused to run, and showed the error below.
Android:
Screen.Recording.2026-07-31.at.6.13.12.PM.mov
iOS:
Screen.Recording.iPhone.17.Pro.07-31-2026.at.5.40.35.PM.mp4
Part of #190305
Pre-launch Checklist
///).