Unverified Commit f0b0b284 authored by Kate Lovett's avatar Kate Lovett Committed by GitHub

Reset missing deprecation for ScrollbarThemeData.copyWith(showTrackOnHover) (#111706)

parent 7f17098f
...@@ -17,6 +17,64 @@ ...@@ -17,6 +17,64 @@
version: 1 version: 1
transforms: transforms:
# Changes made in https://github.com/flutter/flutter/pull/111706
- title: "Migrate to 'trackVisibility'"
date: 2022-09-15
element:
uris: [ 'material.dart' ]
field: 'showTrackOnHover'
inClass: 'Scrollbar'
changes:
- kind: 'rename'
newName: 'trackVisibility'
# Changes made in https://github.com/flutter/flutter/pull/111706
- title: "Migrate to 'trackVisibility'"
date: 2022-09-15
element:
uris: [ 'material.dart' ]
constructor: ''
inClass: 'Scrollbar'
changes:
- kind: 'renameParameter'
oldName: 'showTrackOnHover'
newName: 'trackVisibility'
# Changes made in https://github.com/flutter/flutter/pull/111706
- title: "Migrate to 'trackVisibility'"
date: 2022-09-15
element:
uris: [ 'material.dart' ]
field: 'showTrackOnHover'
inClass: 'ScrollbarThemeData'
changes:
- kind: 'rename'
newName: 'trackVisibility'
# Changes made in https://github.com/flutter/flutter/pull/111706
- title: "Migrate to 'thumbVisibility'"
date: 2022-09-15
element:
uris: [ 'material.dart' ]
constructor: ''
inClass: 'ScrollbarThemeData'
changes:
- kind: 'renameParameter'
oldName: 'showTrackOnHover'
newName: 'trackVisibility'
# Changes made in https://github.com/flutter/flutter/pull/111706
- title: "Migrate to 'trackVisibility'"
date: 2022-09-15
element:
uris: [ 'material.dart' ]
method: 'copyWith'
inClass: 'ScrollbarThemeData'
changes:
- kind: 'renameParameter'
oldName: 'showTrackOnHover'
newName: 'trackVisibility'
# Changes made in https://github.com/flutter/flutter/pull/111080 # Changes made in https://github.com/flutter/flutter/pull/111080
- title: "Migrate to 'BottomAppBarTheme.color'" - title: "Migrate to 'BottomAppBarTheme.color'"
date: 2022-09-07 date: 2022-09-07
......
...@@ -102,7 +102,7 @@ class Scrollbar extends StatelessWidget { ...@@ -102,7 +102,7 @@ class Scrollbar extends StatelessWidget {
this.isAlwaysShown, this.isAlwaysShown,
@Deprecated( @Deprecated(
'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. ' 'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. '
'This feature was deprecated after v2.9.0-1.0.pre.', 'This feature was deprecated after v3.4.0-19.0.pre.',
) )
this.showTrackOnHover, this.showTrackOnHover,
@Deprecated( @Deprecated(
...@@ -168,7 +168,7 @@ class Scrollbar extends StatelessWidget { ...@@ -168,7 +168,7 @@ class Scrollbar extends StatelessWidget {
/// should be used instead. /// should be used instead.
@Deprecated( @Deprecated(
'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. ' 'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. '
'This feature was deprecated after v2.9.0-1.0.pre.', 'This feature was deprecated after v3.4.0-19.0.pre.',
) )
final bool? showTrackOnHover; final bool? showTrackOnHover;
......
...@@ -52,7 +52,7 @@ class ScrollbarThemeData with Diagnosticable { ...@@ -52,7 +52,7 @@ class ScrollbarThemeData with Diagnosticable {
this.isAlwaysShown, this.isAlwaysShown,
@Deprecated( @Deprecated(
'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. ' 'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. '
'This feature was deprecated after v2.9.0-1.0.pre.', 'This feature was deprecated after v3.4.0-19.0.pre.',
) )
this.showTrackOnHover, this.showTrackOnHover,
}) : assert( }) : assert(
...@@ -82,7 +82,7 @@ class ScrollbarThemeData with Diagnosticable { ...@@ -82,7 +82,7 @@ class ScrollbarThemeData with Diagnosticable {
/// descendant [Scrollbar] widgets. /// descendant [Scrollbar] widgets.
@Deprecated( @Deprecated(
'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. ' 'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. '
'This feature was deprecated after v2.9.0-1.0.pre.', 'This feature was deprecated after v3.4.0-19.0.pre.',
) )
final bool? showTrackOnHover; final bool? showTrackOnHover;
...@@ -161,7 +161,6 @@ class ScrollbarThemeData with Diagnosticable { ...@@ -161,7 +161,6 @@ class ScrollbarThemeData with Diagnosticable {
MaterialStateProperty<bool?>? thumbVisibility, MaterialStateProperty<bool?>? thumbVisibility,
MaterialStateProperty<double?>? thickness, MaterialStateProperty<double?>? thickness,
MaterialStateProperty<bool?>? trackVisibility, MaterialStateProperty<bool?>? trackVisibility,
bool? showTrackOnHover,
bool? interactive, bool? interactive,
Radius? radius, Radius? radius,
MaterialStateProperty<Color?>? thumbColor, MaterialStateProperty<Color?>? thumbColor,
...@@ -175,6 +174,12 @@ class ScrollbarThemeData with Diagnosticable { ...@@ -175,6 +174,12 @@ class ScrollbarThemeData with Diagnosticable {
'This feature was deprecated after v2.9.0-1.0.pre.', 'This feature was deprecated after v2.9.0-1.0.pre.',
) )
bool? isAlwaysShown, bool? isAlwaysShown,
@Deprecated(
'Use ScrollbarThemeData.trackVisibility to resolve based on the current state instead. '
'This feature was deprecated after v3.4.0-19.0.pre.',
)
bool? showTrackOnHover,
}) { }) {
return ScrollbarThemeData( return ScrollbarThemeData(
thumbVisibility: thumbVisibility ?? this.thumbVisibility, thumbVisibility: thumbVisibility ?? this.thumbVisibility,
......
...@@ -694,4 +694,11 @@ void main() { ...@@ -694,4 +694,11 @@ void main() {
themeData = ThemeData(bottomAppBarColor: Colors.green); themeData = ThemeData(bottomAppBarColor: Colors.green);
themeData = ThemeData.raw(bottomAppBarColor: Colors.green); themeData = ThemeData.raw(bottomAppBarColor: Colors.green);
themeData = ThemeData.copyWith(bottomAppBarColor: Colors.green); themeData = ThemeData.copyWith(bottomAppBarColor: Colors.green);
// Changes made in https://github.com/flutter/flutter/pull/111706
Scrollbar scrollbar = Scrollbar(showTrackOnHover: true);
bool nowShowing = scrollbar.showTrackOnHover;
ScrollbarThemeData scrollbarTheme = ScrollbarThemeData(showTrackOnHover: nowShowing);
scrollbarTheme.copyWith(showTrackOnHover: nowShowing);
scrollbarTheme.showTrackOnHover;
} }
...@@ -898,4 +898,11 @@ void main() { ...@@ -898,4 +898,11 @@ void main() {
themeData = ThemeData(bottomAppBarTheme: BottomAppBarTheme(color: Colors.green)); themeData = ThemeData(bottomAppBarTheme: BottomAppBarTheme(color: Colors.green));
themeData = ThemeData.raw(bottomAppBarTheme: BottomAppBarTheme(color: Colors.green)); themeData = ThemeData.raw(bottomAppBarTheme: BottomAppBarTheme(color: Colors.green));
themeData = ThemeData.copyWith(bottomAppBarTheme: BottomAppBarTheme(color: Colors.green)); themeData = ThemeData.copyWith(bottomAppBarTheme: BottomAppBarTheme(color: Colors.green));
// Changes made in https://github.com/flutter/flutter/pull/111706
Scrollbar scrollbar = Scrollbar(trackVisibility: true);
bool nowShowing = scrollbar.trackVisibility;
ScrollbarThemeData scrollbarTheme = ScrollbarThemeData(trackVisibility: nowShowing);
scrollbarTheme.copyWith(trackVisibility: nowShowing);
scrollbarTheme.trackVisibility;
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment