Skip to content

Commit

Permalink
changed ripple to color control highlight
Browse files Browse the repository at this point in the history
  • Loading branch information
martinseal committed Sep 11, 2019
1 parent 0aa31b1 commit 3a9eefe
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1314,10 +1314,13 @@ public void showButtonInMenu(boolean animate) {
// return color;
// }


//<item name="colorControlHighlight">@color/ripple_color</item>

private static int getFabPressedColor(Context context) {
int colorAttr;
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
colorAttr = android.R.attr.colorAccent;
colorAttr = android.R.attr.colorControlHighlight;
} else {
//Get colorAccent defined for AppCompat
colorAttr = context.getResources().getIdentifier("fabPressedColor", "attr", context.getPackageName());
Expand All @@ -1330,7 +1333,7 @@ private static int getFabPressedColor(Context context) {
private static int getDefaultFabRippleColor(Context context) {
int colorAttr;
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
colorAttr = android.R.attr.colorAccent;
colorAttr = android.R.attr.colorControlHighlight;
} else {
//Get colorAccent defined for AppCompat
colorAttr = context.getResources().getIdentifier("fabRippleColor", "attr", context.getPackageName());
Expand Down

0 comments on commit 3a9eefe

Please sign in to comment.