Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed the color field from AppBarTheme #73732

Merged
merged 3 commits into from Jan 15, 2021

Conversation

HansMuller
Copy link
Contributor

@HansMuller HansMuller commented Jan 11, 2021

The old color and the new backgroundColor field mean the same thing. The backgroundColor field was added in #71184 for the sake of consistency with AppBar.backgroundColor, however the original color field was not removed. It's now gone and there's an assert for the error of specifying both.

@flutter-dashboard flutter-dashboard bot added f: material design flutter/packages/flutter/material repository. framework flutter/packages/flutter repository. See also f: labels. labels Jan 11, 2021
@google-cla google-cla bot added the cla: yes label Jan 11, 2021
Copy link
Contributor

@darrenaustin darrenaustin left a comment

Choose a reason for hiding this comment

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

LGTM

});
}) : assert(
color == null || backgroundColor == null,
'The color and backgroundColor parameters mean the same thing. Only specify one.'),
Copy link
Contributor

Choose a reason for hiding this comment

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

Perhaps '...parameters are used to describe the same thing.'

@@ -29,8 +29,8 @@ class AppBarTheme with Diagnosticable {
/// Creates a theme that can be used for [ThemeData.appBarTheme].
const AppBarTheme({
this.brightness,
this.color,
this.backgroundColor,
Color? color,
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we want to mark this as deprecated?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I'm going to update some existing use cases first. After that this (and a few other parameters) will definitely be deprecated.

@HansMuller HansMuller force-pushed the remove_appbar_theme_color_field branch from 6839c54 to c9e5aa9 Compare January 15, 2021 03:22
@HansMuller HansMuller merged commit ed0aed7 into flutter:master Jan 15, 2021
@HansMuller HansMuller deleted the remove_appbar_theme_color_field branch January 25, 2021 17:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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.

None yet

2 participants