|
@@ -1,5 +1,6 @@
|
1
|
1
|
package com.reactnativenavigation.utils;
|
2
|
2
|
|
|
3
|
+import android.graphics.Color;
|
3
|
4
|
import android.graphics.PorterDuff;
|
4
|
5
|
import android.graphics.PorterDuffColorFilter;
|
5
|
6
|
import android.graphics.drawable.Drawable;
|
|
@@ -27,8 +28,8 @@ public class ViewUtils {
|
27
|
28
|
});
|
28
|
29
|
}
|
29
|
30
|
|
30
|
|
- public static void tintDrawable(Drawable drawable, int tint) {
|
31
|
|
- drawable.setColorFilter(new PorterDuffColorFilter(tint, PorterDuff.Mode.SRC_IN));
|
|
31
|
+ public static void tintDrawable(Drawable drawable, int tint, boolean enabled) {
|
|
32
|
+ drawable.setColorFilter(new PorterDuffColorFilter(enabled ? tint : Color.LTGRAY, PorterDuff.Mode.SRC_IN));
|
32
|
33
|
}
|
33
|
34
|
|
34
|
35
|
public static float convertDpToPixel(float dp) {
|