Add displayCornerRadii support to predictive back transitions.#181326
Conversation
There was a problem hiding this comment.
Code Review
The pull request successfully integrates MediaQuery.displayCornerRadii into PredictiveBackPageTransitionsBuilder and PredictiveBackFullscreenPageTransitionsBuilder. The changes ensure that if display corner radii are available from the MediaQuery, they are used for ClipRRect widgets, otherwise a fallback value is applied. The comments have been updated to reflect this new behavior, and a comprehensive test case has been added to verify the functionality, especially for Android platforms. The code is clean and follows the established patterns for Flutter widgets.
|
|
||
| // Only Android supports backGesture channel methods. Other platforms will | ||
| // do nothing. | ||
| if (defaultTargetPlatform != TargetPlatform.android) { |
There was a problem hiding this comment.
Can we instead use the variant of the test to tweak this? I.e. have an Android only test and a test for the other platforms
There was a problem hiding this comment.
Or we could only run this test on Android. I think that above this line, the test is not testing anything relevant to the displayCornerRadii feature, it's testing stuff that is already tested elsewhere.
There was a problem hiding this comment.
True, my point was that we can leverage the variant, instead of putting a return in the middle of the test :p
justinmc
left a comment
There was a problem hiding this comment.
Surprisingly straightforward change now that #179219 is done. Thank you @ksokolovskyi for following up here! I'm really excited to fix this. LGTM 👍
|
|
||
| // Only Android supports backGesture channel methods. Other platforms will | ||
| // do nothing. | ||
| if (defaultTargetPlatform != TargetPlatform.android) { |
There was a problem hiding this comment.
Or we could only run this test on Android. I think that above this line, the test is not testing anything relevant to the displayCornerRadii feature, it's testing stuff that is already tested elsewhere.
…isplay-corner-radii
|
@navaronbracke @justinmc thanks a lot for your reviews! I've removed the In the test, we set the |
…isplay-corner-radii
…isplay-corner-radii
…isplay-corner-radii
|
Hi @justinmc @navaronbracke, could you please take another look at this PR when you have time? Thanks! |
…isplay-corner-radii
…isplay-corner-radii
|
@justinmc could you please review this PR one more time? |
…isplay-corner-radii
…isplay-corner-radii
flutter/flutter@d182143...2ec61af 2026-03-08 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from P9D6h4D2ks99Ct7TO... to giLoee6arX5CRHuRh... (flutter/flutter#183366) 2026-03-07 engine-flutter-autoroll@skia.org Roll Skia from 6643c1bd93bb to af994ae4d990 (1 revision) (flutter/flutter#183359) 2026-03-07 34465683+rkishan516@users.noreply.github.com refactor: remove material import from animated_cross_fade, physical_model_test, pinned_header_sliver_test, spell_check_test (flutter/flutter#183234) 2026-03-07 engine-flutter-autoroll@skia.org Roll Skia from a69ef43650ee to 6643c1bd93bb (13 revisions) (flutter/flutter#183346) 2026-03-07 137456488+flutter-pub-roller-bot@users.noreply.github.com Roll pub packages (flutter/flutter#183344) 2026-03-07 engine-flutter-autoroll@skia.org Roll Dart SDK from 0c24edc41e09 to 1604910613c7 (2 revisions) (flutter/flutter#183342) 2026-03-07 engine-flutter-autoroll@skia.org Roll Fuchsia Test Scripts from nR2ESa1Gd8yPcWo06... to R2EllDf4DgBXVNuiN... (flutter/flutter#183341) 2026-03-07 97480502+b-luk@users.noreply.github.com Support BGRA textures in BlitCopyTextureToBufferCommandGLES::Encode and fix improper mapping of BGRA to RGBA in blit_command_gles and texture_gles (flutter/flutter#182397) 2026-03-06 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from 8ay15_eQOEgPHCypm... to P9D6h4D2ks99Ct7TO... (flutter/flutter#183329) 2026-03-06 41930132+hellohuanlin@users.noreply.github.com [doc]add discord channel to ios triage meeting (flutter/flutter#183285) 2026-03-06 engine-flutter-autoroll@skia.org Roll Dart SDK from 7c7c1e3d024d to 0c24edc41e09 (2 revisions) (flutter/flutter#183328) 2026-03-06 43054281+camsim99@users.noreply.github.com Revert "Make HCPP upgrading work for vd/tlhc (#181024)" (flutter/flutter#183310) 2026-03-06 stuartmorgan@google.com Add AI contribution guidelines (flutter/flutter#183326) 2026-03-06 jason-simmons@users.noreply.github.com [Impeller] Do not wait for a frame's acquire fence if the frame was never presented (flutter/flutter#183288) 2026-03-06 jacksongardner@google.com Add back in accidentally removed line from `create_updated_flutter_deps.py` (flutter/flutter#183314) 2026-03-06 matt.boetger@gmail.com Fix typo in README (flutter/flutter#183245) 2026-03-06 137456488+flutter-pub-roller-bot@users.noreply.github.com Roll pub packages (flutter/flutter#183319) 2026-03-06 sokolovskyi.konstantin@gmail.com Add displayCornerRadii support to predictive back transitions. (flutter/flutter#181326) 2026-03-06 34465683+rkishan516@users.noreply.github.com refactor: remove material from widget_inspector_test, sliver_cross_axis_group_test, editable_text_show_on_screen_test, scrollable_fling_test, selection_container_test (flutter/flutter#182702) 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 bmparr@google.com,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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…er#181326) Closes flutter#178463 - Adds support of `MediaQuery.displayCornerRadii` to `PredictiveBackPageTransitionsBuilder` - Adds support of `MediaQuery.displayCornerRadii` to `PredictiveBackFullscreenPageTransitionsBuilder` ## Pre-launch Checklist - [X] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [X] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [X] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement]. - [X] I signed the [CLA]. - [X] I listed at least one issue that this PR fixes in the description above. - [X] I updated/added relevant documentation (doc comments with `///`). - [X] I added new tests to check the change I am making, or this PR is [test-exempt]. - [X] I followed the [breaking change policy] and added [Data Driven Fixes] where supported. - [X] All existing and new tests are passing. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview [Tree Hygiene]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md [test-exempt]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests [Flutter Style Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md [Features we expect every widget to implement]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md [Data Driven Fixes]: https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
…r#11202) flutter/flutter@d182143...2ec61af 2026-03-08 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from P9D6h4D2ks99Ct7TO... to giLoee6arX5CRHuRh... (flutter/flutter#183366) 2026-03-07 engine-flutter-autoroll@skia.org Roll Skia from 6643c1bd93bb to af994ae4d990 (1 revision) (flutter/flutter#183359) 2026-03-07 34465683+rkishan516@users.noreply.github.com refactor: remove material import from animated_cross_fade, physical_model_test, pinned_header_sliver_test, spell_check_test (flutter/flutter#183234) 2026-03-07 engine-flutter-autoroll@skia.org Roll Skia from a69ef43650ee to 6643c1bd93bb (13 revisions) (flutter/flutter#183346) 2026-03-07 137456488+flutter-pub-roller-bot@users.noreply.github.com Roll pub packages (flutter/flutter#183344) 2026-03-07 engine-flutter-autoroll@skia.org Roll Dart SDK from 0c24edc41e09 to 1604910613c7 (2 revisions) (flutter/flutter#183342) 2026-03-07 engine-flutter-autoroll@skia.org Roll Fuchsia Test Scripts from nR2ESa1Gd8yPcWo06... to R2EllDf4DgBXVNuiN... (flutter/flutter#183341) 2026-03-07 97480502+b-luk@users.noreply.github.com Support BGRA textures in BlitCopyTextureToBufferCommandGLES::Encode and fix improper mapping of BGRA to RGBA in blit_command_gles and texture_gles (flutter/flutter#182397) 2026-03-06 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from 8ay15_eQOEgPHCypm... to P9D6h4D2ks99Ct7TO... (flutter/flutter#183329) 2026-03-06 41930132+hellohuanlin@users.noreply.github.com [doc]add discord channel to ios triage meeting (flutter/flutter#183285) 2026-03-06 engine-flutter-autoroll@skia.org Roll Dart SDK from 7c7c1e3d024d to 0c24edc41e09 (2 revisions) (flutter/flutter#183328) 2026-03-06 43054281+camsim99@users.noreply.github.com Revert "Make HCPP upgrading work for vd/tlhc (#181024)" (flutter/flutter#183310) 2026-03-06 stuartmorgan@google.com Add AI contribution guidelines (flutter/flutter#183326) 2026-03-06 jason-simmons@users.noreply.github.com [Impeller] Do not wait for a frame's acquire fence if the frame was never presented (flutter/flutter#183288) 2026-03-06 jacksongardner@google.com Add back in accidentally removed line from `create_updated_flutter_deps.py` (flutter/flutter#183314) 2026-03-06 matt.boetger@gmail.com Fix typo in README (flutter/flutter#183245) 2026-03-06 137456488+flutter-pub-roller-bot@users.noreply.github.com Roll pub packages (flutter/flutter#183319) 2026-03-06 sokolovskyi.konstantin@gmail.com Add displayCornerRadii support to predictive back transitions. (flutter/flutter#181326) 2026-03-06 34465683+rkishan516@users.noreply.github.com refactor: remove material from widget_inspector_test, sliver_cross_axis_group_test, editable_text_show_on_screen_test, scrollable_fling_test, selection_container_test (flutter/flutter#182702) 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 bmparr@google.com,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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
…er#181326) Closes flutter#178463 - Adds support of `MediaQuery.displayCornerRadii` to `PredictiveBackPageTransitionsBuilder` - Adds support of `MediaQuery.displayCornerRadii` to `PredictiveBackFullscreenPageTransitionsBuilder` ## Pre-launch Checklist - [X] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [X] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [X] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement]. - [X] I signed the [CLA]. - [X] I listed at least one issue that this PR fixes in the description above. - [X] I updated/added relevant documentation (doc comments with `///`). - [X] I added new tests to check the change I am making, or this PR is [test-exempt]. - [X] I followed the [breaking change policy] and added [Data Driven Fixes] where supported. - [X] All existing and new tests are passing. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview [Tree Hygiene]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md [test-exempt]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests [Flutter Style Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md [Features we expect every widget to implement]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md [Data Driven Fixes]: https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
…er#181326) Closes flutter#178463 - Adds support of `MediaQuery.displayCornerRadii` to `PredictiveBackPageTransitionsBuilder` - Adds support of `MediaQuery.displayCornerRadii` to `PredictiveBackFullscreenPageTransitionsBuilder` ## Pre-launch Checklist - [X] I read the [Contributor Guide] and followed the process outlined there for submitting PRs. - [X] I read the [Tree Hygiene] wiki page, which explains my responsibilities. - [X] I read and followed the [Flutter Style Guide], including [Features we expect every widget to implement]. - [X] I signed the [CLA]. - [X] I listed at least one issue that this PR fixes in the description above. - [X] I updated/added relevant documentation (doc comments with `///`). - [X] I added new tests to check the change I am making, or this PR is [test-exempt]. - [X] I followed the [breaking change policy] and added [Data Driven Fixes] where supported. - [X] All existing and new tests are passing. <!-- Links --> [Contributor Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#overview [Tree Hygiene]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md [test-exempt]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#tests [Flutter Style Guide]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md [Features we expect every widget to implement]: https://github.com/flutter/flutter/blob/main/docs/contributing/Style-guide-for-Flutter-repo.md#features-we-expect-every-widget-to-implement [CLA]: https://cla.developers.google.com/ [flutter/tests]: https://github.com/flutter/tests [breaking change policy]: https://github.com/flutter/flutter/blob/main/docs/contributing/Tree-hygiene.md#handling-breaking-changes [Discord]: https://github.com/flutter/flutter/blob/main/docs/contributing/Chat.md [Data Driven Fixes]: https://github.com/flutter/flutter/blob/main/docs/contributing/Data-driven-Fixes.md
…r#11202) flutter/flutter@d182143...2ec61af 2026-03-08 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from P9D6h4D2ks99Ct7TO... to giLoee6arX5CRHuRh... (flutter/flutter#183366) 2026-03-07 engine-flutter-autoroll@skia.org Roll Skia from 6643c1bd93bb to af994ae4d990 (1 revision) (flutter/flutter#183359) 2026-03-07 34465683+rkishan516@users.noreply.github.com refactor: remove material import from animated_cross_fade, physical_model_test, pinned_header_sliver_test, spell_check_test (flutter/flutter#183234) 2026-03-07 engine-flutter-autoroll@skia.org Roll Skia from a69ef43650ee to 6643c1bd93bb (13 revisions) (flutter/flutter#183346) 2026-03-07 137456488+flutter-pub-roller-bot@users.noreply.github.com Roll pub packages (flutter/flutter#183344) 2026-03-07 engine-flutter-autoroll@skia.org Roll Dart SDK from 0c24edc41e09 to 1604910613c7 (2 revisions) (flutter/flutter#183342) 2026-03-07 engine-flutter-autoroll@skia.org Roll Fuchsia Test Scripts from nR2ESa1Gd8yPcWo06... to R2EllDf4DgBXVNuiN... (flutter/flutter#183341) 2026-03-07 97480502+b-luk@users.noreply.github.com Support BGRA textures in BlitCopyTextureToBufferCommandGLES::Encode and fix improper mapping of BGRA to RGBA in blit_command_gles and texture_gles (flutter/flutter#182397) 2026-03-06 engine-flutter-autoroll@skia.org Roll Fuchsia Linux SDK from 8ay15_eQOEgPHCypm... to P9D6h4D2ks99Ct7TO... (flutter/flutter#183329) 2026-03-06 41930132+hellohuanlin@users.noreply.github.com [doc]add discord channel to ios triage meeting (flutter/flutter#183285) 2026-03-06 engine-flutter-autoroll@skia.org Roll Dart SDK from 7c7c1e3d024d to 0c24edc41e09 (2 revisions) (flutter/flutter#183328) 2026-03-06 43054281+camsim99@users.noreply.github.com Revert "Make HCPP upgrading work for vd/tlhc (#181024)" (flutter/flutter#183310) 2026-03-06 stuartmorgan@google.com Add AI contribution guidelines (flutter/flutter#183326) 2026-03-06 jason-simmons@users.noreply.github.com [Impeller] Do not wait for a frame's acquire fence if the frame was never presented (flutter/flutter#183288) 2026-03-06 jacksongardner@google.com Add back in accidentally removed line from `create_updated_flutter_deps.py` (flutter/flutter#183314) 2026-03-06 matt.boetger@gmail.com Fix typo in README (flutter/flutter#183245) 2026-03-06 137456488+flutter-pub-roller-bot@users.noreply.github.com Roll pub packages (flutter/flutter#183319) 2026-03-06 sokolovskyi.konstantin@gmail.com Add displayCornerRadii support to predictive back transitions. (flutter/flutter#181326) 2026-03-06 34465683+rkishan516@users.noreply.github.com refactor: remove material from widget_inspector_test, sliver_cross_axis_group_test, editable_text_show_on_screen_test, scrollable_fling_test, selection_container_test (flutter/flutter#182702) 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 bmparr@google.com,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://issues.skia.org/issues/new?component=1389291&template=1850622 Documentation for the AutoRoller is here: https://skia.googlesource.com/buildbot/+doc/main/autoroll/README.md
Closes #178463
MediaQuery.displayCornerRadiitoPredictiveBackPageTransitionsBuilderMediaQuery.displayCornerRadiitoPredictiveBackFullscreenPageTransitionsBuilderPre-launch Checklist
///).