From 20670bfc9787400f2f9083aa2e12ad93ca9e1d8e Mon Sep 17 00:00:00 2001 From: SavagePeanut Date: Mon, 18 Mar 2024 04:30:13 +0000 Subject: [PATCH] swap custom_theme_background_secondary_dark and custom_theme_background_tertiary_dark default and calculated values --- src/cheogram/res/values/colors.xml | 4 ++-- src/main/java/eu/siacs/conversations/utils/ThemeHelper.java | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/cheogram/res/values/colors.xml b/src/cheogram/res/values/colors.xml index a391bea697fb54535bbefdaaaad87133cd0fc4ce..7bd3a36975dd610baf8e884c3322fb006e55c283 100644 --- a/src/cheogram/res/values/colors.xml +++ b/src/cheogram/res/values/colors.xml @@ -14,8 +14,8 @@ @color/grey300 @color/grey800 - @color/grey700 - @color/grey900 + @color/grey900 + @color/grey700 @color/black_perpy @color/black_perpy diff --git a/src/main/java/eu/siacs/conversations/utils/ThemeHelper.java b/src/main/java/eu/siacs/conversations/utils/ThemeHelper.java index 2f6fd2e1dcb2887dfb6f7dcaf41aa84bc27c5be7..ae3ed02d5797e3568076ca8314009a12fa9a55ee 100644 --- a/src/main/java/eu/siacs/conversations/utils/ThemeHelper.java +++ b/src/main/java/eu/siacs/conversations/utils/ThemeHelper.java @@ -81,8 +81,8 @@ public class ThemeHelper { int green = (background_primary >> 8) & 0xFF; int blue = background_primary & 0xFF; colors.put(R.color.custom_theme_background_primary_dark, background_primary); - colors.put(R.color.custom_theme_background_secondary_dark, (int)((alpha << 24) | ((int)(40 + red*.84) << 16) | ((int)(40 + green*.84) << 8) | (int)(40 + blue*.84))); - colors.put(R.color.custom_theme_background_tertiary_dark, (int)((alpha << 24) | ((int)(red*.5) << 16) | ((int)(green*.5) << 8) | (int)(blue*.5))); + colors.put(R.color.custom_theme_background_secondary_dark, (int)((alpha << 24) | ((int)(red*.5) << 16) | ((int)(green*.5) << 8) | (int)(blue*.5))); + colors.put(R.color.custom_theme_background_tertiary_dark, (int)((alpha << 24) | ((int)(40 + red*.84) << 16) | ((int)(40 + green*.84) << 8) | (int)(40 + blue*.84))); } if (colors.isEmpty()) return colors;