updated msg recoloring
This commit is contained in:
@@ -4,6 +4,7 @@ import android.app.Activity;
|
||||
import android.content.Context;
|
||||
import android.content.res.ColorStateList;
|
||||
import android.graphics.Color;
|
||||
import android.graphics.PorterDuff;
|
||||
import android.graphics.drawable.Drawable;
|
||||
import android.os.Build;
|
||||
import android.util.Log;
|
||||
@@ -11,6 +12,8 @@ import android.view.View;
|
||||
import android.view.Window;
|
||||
import android.webkit.WebView;
|
||||
import android.widget.ImageButton;
|
||||
import android.widget.ImageView;
|
||||
import android.widget.TextView;
|
||||
import androidx.appcompat.app.AppCompatDelegate;
|
||||
import androidx.appcompat.widget.Toolbar;
|
||||
import androidx.core.graphics.ColorUtils;
|
||||
@@ -197,11 +200,23 @@ public class ThemesUtils {
|
||||
toolbar.setElevation(0.0f);
|
||||
}
|
||||
|
||||
public static void setImageViewColored(ImageView view){
|
||||
view.setColorFilter(ThemesUtils.getAccentColor(), PorterDuff.Mode.MULTIPLY);
|
||||
}
|
||||
|
||||
public static Drawable recolorDrawable(Drawable drawable) {
|
||||
if (drawable == null) return null;
|
||||
return new RecoloredDrawable(drawable, getAccentColor());
|
||||
} // Recolor drawable to accent color
|
||||
|
||||
public static void recolorTextView(TextView tw) {
|
||||
tw.getBackground().setColorFilter(ThemesUtils.getAccentColor(), PorterDuff.Mode.SRC_OVER);
|
||||
}
|
||||
|
||||
public static void recolorBGView(View view) {
|
||||
view.getBackground().setColorFilter(ThemesUtils.getAccentColor(), PorterDuff.Mode.SRC_OVER);
|
||||
}
|
||||
|
||||
public static Drawable recolorVKIconMenu(Drawable drawable) {
|
||||
int accent = getHeaderText();
|
||||
|
||||
|
||||
@@ -92,6 +92,10 @@
|
||||
|
||||
move-result-object v0
|
||||
|
||||
invoke-static {v0}, Lru/vtosters/lite/utils/ThemesUtils;->recolorDrawable(Landroid/graphics/drawable/Drawable;)Landroid/graphics/drawable/Drawable;
|
||||
|
||||
move-result-object v0
|
||||
|
||||
invoke-virtual {v0}, Landroid/graphics/drawable/Drawable;->mutate()Landroid/graphics/drawable/Drawable;
|
||||
|
||||
move-result-object v0
|
||||
|
||||
@@ -321,6 +321,8 @@
|
||||
|
||||
invoke-virtual {v0, v1}, Landroid/widget/TextView;->setBackground(Landroid/graphics/drawable/Drawable;)V
|
||||
|
||||
invoke-static {v0}, Lru/vtosters/lite/utils/ThemesUtils;->recolorTextView(Landroid/widget/TextView;)V
|
||||
|
||||
.line 6
|
||||
sget v1, Lcom/vk/im/ui/o;->ScrollToBottomView_vkim_stb_counter_fontFamily:I
|
||||
|
||||
|
||||
@@ -65,6 +65,7 @@
|
||||
|
||||
invoke-virtual {v0, v1}, Landroid/view/View;->setVisibility(I)V
|
||||
|
||||
|
||||
const/4 v1, 0x0
|
||||
|
||||
const v2, 0x1020019
|
||||
|
||||
Reference in New Issue
Block a user