Skip to content

Conversation

@Piinks
Copy link
Contributor

@Piinks Piinks commented Sep 15, 2022

Found this while completing an audit for the next batch of deprecations to be removed from the framework.

Scrollbar and ScrollbarThemeData showTrackOnHover is deprecated, but the later .copyWith was not notated for it. This adds the deprecation notation and resets the clock for the bunch.

It also adds a dart fix for this deprecation.

Pre-launch Checklist

  • I read the Contributor Guide and followed the process outlined there for submitting PRs.
  • I read the Tree Hygiene wiki page, which explains my responsibilities.
  • I read and followed the Flutter Style Guide, including Features we expect every widget to implement.
  • I signed the CLA.
  • I listed at least one issue that this PR fixes in the description above.
  • I updated/added relevant documentation (doc comments with ///).
  • I added new tests to check the change I am making, or this PR is test-exempt.
  • All existing and new tests are passing.

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

@Piinks Piinks added c: contributor-productivity Team-specific productivity, code health, technical debt. framework flutter/packages/flutter repository. See also f: labels. f: scrolling Viewports, list views, slivers, etc. c: tech-debt Technical debt, code quality, testing, etc. labels Sep 15, 2022
@flutter-dashboard flutter-dashboard bot added the f: material design flutter/packages/flutter/material repository. label Sep 15, 2022
// Changes made in https://github.com/flutter/flutter/pull/111706
Scrollbar scrollbar = Scrollbar(trackVisibility: true);
bool nowShowing = scrollbar.trackVisibility;
ScrollbarThemeData scrollbarTheme = ScrollbarThemeData(trackVisibility: nowShowing);
Copy link
Member

Choose a reason for hiding this comment

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

trackVisibility in ScrollbarThemeData is type of MaterialStateProperty<bool?>?, can this fix works well?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, it's not a 100% fix, but we did the same transformation for isAlwaysShown ➡️ thumbVisibility.

In general, if we can point folks in the right direction, I think it's helpful. :)

Copy link
Member

@xu-baolin xu-baolin left a comment

Choose a reason for hiding this comment

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

LGTM

@Piinks Piinks added the autosubmit Merge PR when tree becomes green via auto submit App label Sep 16, 2022
@auto-submit auto-submit bot merged commit f0b0b28 into flutter:master Sep 16, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/packages that referenced this pull request Sep 17, 2022
engine-flutter-autoroll added a commit to engine-flutter-autoroll/plugins that referenced this pull request Sep 17, 2022
auto-submit bot pushed a commit that referenced this pull request Mar 13, 2024
)

This PR is to remove deprecated `Scrollbar.showTrackOnHover` and `ScrollbarThemeData.showTrackOnHover`.

These parameters are made obsolete in #111706.
Part of #143956
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

autosubmit Merge PR when tree becomes green via auto submit App c: contributor-productivity Team-specific productivity, code health, technical debt. c: tech-debt Technical debt, code quality, testing, etc. f: material design flutter/packages/flutter/material repository. f: scrolling Viewports, list views, slivers, etc. framework flutter/packages/flutter repository. See also f: labels.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants