Skip to content

Conversation

@ValentinVignal
Copy link
Contributor

Follow up #175573

Migrate the remaining files from MaterialStateMouseCursor to WidgetStateMouseCursor . This PR only focus on WidgetStateColor.

  • This minimizes conflicts and reduces the size of the PR for easier reviews and follow up
  • I'll work on the other elements of packages/flutter/lib/src/material/material_state.dart into other PRs

Pre-launch Checklist

If you need help, consider asking for advice on the #hackers-new channel on Discord.

Note: The Flutter team is currently trialing the use of Gemini Code Assist for GitHub. Comments from the gemini-code-assist bot should not be taken as authoritative feedback from the Flutter team. If you find its comments useful you can update your code accordingly, but if you are unsure or disagree with the feedback, please feel free to wait for a Flutter team member's review for guidance on which automated comments should be addressed.

@github-actions github-actions bot added a: text input Entering text in a text field or keyboard related problems framework flutter/packages/flutter repository. See also f: labels. f: material design flutter/packages/flutter/material repository. labels Sep 25, 2025
Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request continues the migration from the deprecated MaterialStateMouseCursor to WidgetStateMouseCursor. The changes are applied across multiple files in the material package, its corresponding tests, a code generation template, and documentation. This is a straightforward refactoring, replacing all occurrences of the old class with the new one, including updating class inheritance and debug descriptions where necessary.

Copy link
Contributor

@victorsanni victorsanni 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

@victorsanni victorsanni left a comment

Choose a reason for hiding this comment

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

To fix the linux analyze errors, remove the following unused imports:

warning • Unused import: 'material_state.dart' • packages/flutter/lib/src/material/bottom_navigation_bar.dart:22:8 • unused_import
warning • Unused import: 'material_state.dart' • packages/flutter/lib/src/material/button.dart:23:8 • unused_import
warning • Unused import: 'material_state.dart' • packages/flutter/lib/src/material/dropdown.dart:31:8 • unused_import
warning • Unused import: 'material_state.dart' • packages/flutter/lib/src/material/floating_action_button.dart:19:8 • unused_import
warning • Unused import: 'material_state.dart' • packages/flutter/lib/src/material/popup_menu.dart:29:8 • unused_import
warning • Unused import: 'material_state.dart' • packages/flutter/lib/src/material/radio.dart:19:8 • unused_import
warning • Unused import: 'material_state.dart' • packages/flutter/lib/src/material/tabs.dart:24:8 • unused_import

Copy link
Contributor

@QuncCccccc QuncCccccc left a comment

Choose a reason for hiding this comment

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

LGTM. Thanks for the update:)

@ValentinVignal
Copy link
Contributor Author

It looks like Linux tool_integration_tests_5_7 keeps being interrupted

@QuncCccccc QuncCccccc added the autosubmit Merge PR when tree becomes green via auto submit App label Sep 26, 2025
@auto-submit auto-submit bot added this pull request to the merge queue Sep 26, 2025
Merged via the queue into flutter:master with commit 271338b Sep 26, 2025
156 checks passed
@flutter-dashboard flutter-dashboard bot removed the autosubmit Merge PR when tree becomes green via auto submit App label Sep 26, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 26, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 26, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 26, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 27, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 27, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 28, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 28, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 28, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 29, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 29, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 29, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 29, 2025
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 29, 2025
auto-submit bot pushed a commit to flutter/packages that referenced this pull request Sep 29, 2025
Roll Flutter from 6cc976ec26d3 to 96fe3b3df509 (32 revisions)

flutter/flutter@6cc976e...96fe3b3

2025-09-29 [email protected] Roll Packages from 389c678 to 34eec78 (6 revisions) (flutter/flutter#176205)
2025-09-29 [email protected] Roll Skia from 9b2b942d1eb1 to bb3b6bd4be0d (4 revisions) (flutter/flutter#176201)
2025-09-29 [email protected] [ Widget Preview ] Improve IDE integration support (flutter/flutter#176114)
2025-09-29 [email protected] Fix name of driver file (flutter/flutter#176186)
2025-09-29 [email protected] Roll Skia from beb673968802 to 9b2b942d1eb1 (3 revisions) (flutter/flutter#176190)
2025-09-28 [email protected] Roll Fuchsia Linux SDK from 0Z45OXT_Wb8aWI3a0... to 8zjcJic_DtvB2Bo2x... (flutter/flutter#176158)
2025-09-28 [email protected] Revert "[Impeller] Optimize scale translate rectangle transforms" (flutter/flutter#176161)
2025-09-27 [email protected] Roll Skia from 2e5da5c0a9cd to beb673968802 (1 revision) (flutter/flutter#176145)
2025-09-27 [email protected] [Impeller] Optimize scale translate rectangle transforms (flutter/flutter#176123)
2025-09-27 [email protected] Roll Skia from d8422aaf8f89 to 2e5da5c0a9cd (2 revisions) (flutter/flutter#176141)
2025-09-27 [email protected] [web] Remove mention of non-existent `canvaskit_lock.yaml` (flutter/flutter#176108)
2025-09-27 [email protected] Roll Skia from 96b73f61fe61 to d8422aaf8f89 (2 revisions) (flutter/flutter#176118)
2025-09-27 [email protected] [a11y] Add `expanded` flag support to Android. (flutter/flutter#174981)
2025-09-26 [email protected] Make sure that a DesktopTextSelectionToolbar doesn't crash in 0x0 env… (flutter/flutter#173928)
2025-09-26 [email protected] Roll Dart SDK from 899c7340cc4c to af31d2637b6b (11 revisions) (flutter/flutter#176056)
2025-09-26 [email protected] Update java version ranges with the top end limitation for java pre 17 (flutter/flutter#176049)
2025-09-26 [email protected] Add warn java evaluation to android_workflow (flutter/flutter#176097)
2025-09-26 [email protected] Removes type annotations in templates (flutter/flutter#176106)
2025-09-26 [email protected] Marks Linux_pixel_7pro static_path_stroke_tessellation_perf__timeline_summary to be unflaky (flutter/flutter#175917)
2025-09-26 [email protected] Add kotlin/kgp 2.2.* evaluation criteria.  (flutter/flutter#176094)
2025-09-26 [email protected] Migrate to `WidgetStateMouseCursor` (flutter/flutter#175981)
2025-09-26 [email protected] Roll Packages from 117bf63 to 389c678 (4 revisions) (flutter/flutter#176092)
2025-09-26 [email protected] Fix link to .gclient setup instructions (flutter/flutter#176046)
2025-09-26 [email protected] Implement Regular Windows for the win32 framework + add an example application for regular windows (flutter/flutter#173715)
2025-09-26 [email protected] Roll Skia from 5d99c3fc7c83 to 96b73f61fe61 (3 revisions) (flutter/flutter#176075)
2025-09-26 [email protected] Roll Fuchsia Linux SDK from naeytagBIBEpKgZNZ... to 0Z45OXT_Wb8aWI3a0... (flutter/flutter#176068)
2025-09-26 [email protected] Add itemClipBehavior property for CarouselView's children (flutter/flutter#175324)
2025-09-26 [email protected] Roll Skia from 55436d87e414 to 5d99c3fc7c83 (4 revisions) (flutter/flutter#176060)
2025-09-26 [email protected] Revert "[Impeller] Optimize scale translate rectangle transforms" (flutter/flutter#176061)
2025-09-25 98614782+auto-submit[bot]@users.noreply.github.com Reverts "Reapply "Update the AccessibilityPlugin::Announce method to account f… (#174365)" (flutter/flutter#176059)
2025-09-25 [email protected] Make sure that a CupertinoDesktopTextSelectionToolbarButton doesn't c… (flutter/flutter#173894)
2025-09-25 [email protected] Improve code quality in `SensitiveContentPluginTest.java` (flutter/flutter#175721)

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 [email protected] 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
...
github-merge-queue bot pushed a commit that referenced this pull request Sep 30, 2025
Follow up #175981

Migrate the remaining files from `MaterialStateBorderSide ` to
`WidgetStateBorderSide `. This PR only focus on `WidgetStateBorderSide`.

- This minimizes conflicts and reduces the size of the PR for easier
reviews and follow up
- I'll work on the other elements of
`packages/flutter/lib/src/material/material_state.dart` into other PRs

## 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].
- [ ] 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.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.

<!-- 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
okorohelijah pushed a commit to okorohelijah/flutter that referenced this pull request Oct 7, 2025
Follow up flutter#175981

Migrate the remaining files from `MaterialStateBorderSide ` to
`WidgetStateBorderSide `. This PR only focus on `WidgetStateBorderSide`.

- This minimizes conflicts and reduces the size of the PR for easier
reviews and follow up
- I'll work on the other elements of
`packages/flutter/lib/src/material/material_state.dart` into other PRs

## 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].
- [ ] 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.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.

<!-- 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
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Nov 12, 2025
reidbaker pushed a commit to AbdeMohlbi/flutter that referenced this pull request Dec 10, 2025
Follow up flutter#175573

Migrate the remaining files from `MaterialStateMouseCursor ` to
`WidgetStateMouseCursor `. This PR only focus on `WidgetStateColor`.

- This minimizes conflicts and reduces the size of the PR for easier
reviews and follow up
- I'll work on the other elements of
`packages/flutter/lib/src/material/material_state.dart` into other PRs

## 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].
- [ ] 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.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.

<!-- 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
reidbaker pushed a commit to AbdeMohlbi/flutter that referenced this pull request Dec 10, 2025
Follow up flutter#175981

Migrate the remaining files from `MaterialStateBorderSide ` to
`WidgetStateBorderSide `. This PR only focus on `WidgetStateBorderSide`.

- This minimizes conflicts and reduces the size of the PR for easier
reviews and follow up
- I'll work on the other elements of
`packages/flutter/lib/src/material/material_state.dart` into other PRs

## 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].
- [ ] 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.

If you need help, consider asking for advice on the #hackers-new channel
on [Discord].

**Note**: The Flutter team is currently trialing the use of [Gemini Code
Assist for
GitHub](https://developers.google.com/gemini-code-assist/docs/review-github-code).
Comments from the `gemini-code-assist` bot should not be taken as
authoritative feedback from the Flutter team. If you find its comments
useful you can update your code accordingly, but if you are unsure or
disagree with the feedback, please feel free to wait for a Flutter team
member's review for guidance on which automated comments should be
addressed.

<!-- 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
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

a: text input Entering text in a text field or keyboard related problems 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.

3 participants