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

[Theme] Color utility to resolving material theme color attrs programmatically #1656

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

gabrielemariotti
Copy link
Contributor

Added a class utility to resolve material theme color attrs programmatically using the MaterialColors.

import com.google.android.material.R;

/** Utility methods for {@link MaterialColors}. */
public class MaterialColorUtils {
Copy link
Contributor

Choose a reason for hiding this comment

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

I think it will be better to define this as an enum class under MaterialColors, say, MaterialColors.Color.PRIMARY, etc., and provide getColor() method for the enum class.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
4 participants