Rewrote Theme

This commit is contained in:
NoodleMage
2016-03-12 14:22:40 +01:00
committed by NoodleMage
parent 98d420d5aa
commit 5ef5f9b45f
112 changed files with 1078 additions and 1536 deletions
@@ -2,6 +2,7 @@ package eu.kanade.tachiyomi.util
import android.support.annotation.DrawableRes
import android.support.v4.content.ContextCompat
import android.support.v4.graphics.drawable.DrawableCompat
import android.widget.ImageView
/**
@@ -11,7 +12,9 @@ import android.widget.ImageView
*/
fun ImageView.setDrawableCompat(@DrawableRes drawable: Int?) {
if (drawable != null) {
setImageDrawable(ContextCompat.getDrawable(context, drawable))
var drawable = ContextCompat.getDrawable(context, drawable)
DrawableCompat.setTint(drawable,this.context.theme.getResourceColor(android.R.attr.textColorHint))
setImageDrawable(drawable)
} else {
setImageResource(android.R.color.transparent)
}