Color color = new Color(context.getResources().getColor(R.color.bus_departures_hover));
As seen, I am attemping to create a Color object from a resource. This ain't working though!
What has worked for me is:
Color c = new Color(ContextCompat.getColor(context, R.color.yourColor));
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With