diff --git a/app/src/main/java/awais/instagrabber/utils/SettingsHelper.java b/app/src/main/java/awais/instagrabber/utils/SettingsHelper.java
index 839f6d99..a62dc9a8 100755
--- a/app/src/main/java/awais/instagrabber/utils/SettingsHelper.java
+++ b/app/src/main/java/awais/instagrabber/utils/SettingsHelper.java
@@ -113,7 +113,7 @@ public final class SettingsHelper {
@StringDef(
{APP_LANGUAGE, APP_THEME, COOKIE, FOLDER_PATH, DATE_TIME_FORMAT, DATE_TIME_SELECTION, CUSTOM_DATE_TIME_FORMAT,
- DEVICE_UUID, SKIPPED_VERSION, DEFAULT_TAB, STORY_VIEWER})
+ DEVICE_UUID, SKIPPED_VERSION, DEFAULT_TAB, STORY_VIEWER, PREF_DARK_THEME, PREF_LIGHT_THEME})
public @interface StringSettings {}
@StringDef({DOWNLOAD_USER_FOLDER, FOLDER_SAVE_TO, AUTOPLAY_VIDEOS, SHOW_QUICK_ACCESS_DIALOG, MUTED_VIDEOS,
@@ -121,6 +121,6 @@ public final class SettingsHelper {
CHECK_ACTIVITY, CHECK_UPDATES})
public @interface BooleanSettings {}
- @StringDef({PREV_INSTALL_VERSION, PREF_DARK_THEME, PREF_LIGHT_THEME})
+ @StringDef({PREV_INSTALL_VERSION})
public @interface IntegerSettings {}
}
\ No newline at end of file
diff --git a/app/src/main/java/awais/instagrabber/utils/ThemeUtils.java b/app/src/main/java/awais/instagrabber/utils/ThemeUtils.java
index 4962d2f2..bf3f94f8 100644
--- a/app/src/main/java/awais/instagrabber/utils/ThemeUtils.java
+++ b/app/src/main/java/awais/instagrabber/utils/ThemeUtils.java
@@ -3,6 +3,7 @@ package awais.instagrabber.utils;
import android.content.Context;
import android.content.res.Configuration;
import android.os.Build;
+import android.util.Log;
import androidx.annotation.NonNull;
import androidx.appcompat.app.AppCompatDelegate;
@@ -23,8 +24,13 @@ public final class ThemeUtils {
themeCode = AppCompatDelegate.MODE_NIGHT_AUTO_BATTERY;
}
final boolean isNight = isNight(context, themeCode);
- final int themeResId = isNight ? settingsHelper.getInteger(Constants.PREF_DARK_THEME)
- : settingsHelper.getInteger(Constants.PREF_LIGHT_THEME);
+ int themeResId = 0;
+ try {
+ themeResId = Integer.parseInt(isNight ? settingsHelper.getString(Constants.PREF_DARK_THEME)
+ : settingsHelper.getString(Constants.PREF_LIGHT_THEME));
+ } catch (NumberFormatException e) {
+ Log.e(TAG, "changeTheme: ", e);
+ }
final int finalThemeResId;
if (themeResId <= 0) {
diff --git a/app/src/main/res/values/arrays.xml b/app/src/main/res/values/arrays.xml
index 36e8abbc..ca1b4bea 100755
--- a/app/src/main/res/values/arrays.xml
+++ b/app/src/main/res/values/arrays.xml
@@ -119,9 +119,11 @@
- @string/light_white_theme
+ - @string/light_barinsta_theme
- @style/AppTheme.Light.White
+ - @style/AppTheme.Light.Barinsta
- @string/dark_black_theme
diff --git a/app/src/main/res/values/color.xml b/app/src/main/res/values/color.xml
index d418393d..8eeecd13 100755
--- a/app/src/main/res/values/color.xml
+++ b/app/src/main/res/values/color.xml
@@ -33,9 +33,6 @@
#efefef
#80000000
-
- #000000
-
#FFFFFF
#000000
@@ -67,4 +64,14 @@
#2962FF
#66BB6A
+
+
+ #a86735
+ #dd9561
+ #753c0a
+ #d4ab7c
+ #ffddac
+ #a17c4f
+ #616161
+ @color/black
\ No newline at end of file
diff --git a/app/src/main/res/values/strings.xml b/app/src/main/res/values/strings.xml
index 14604d74..d7c7f254 100755
--- a/app/src/main/res/values/strings.xml
+++ b/app/src/main/res/values/strings.xml
@@ -281,4 +281,5 @@
Black
Light theme
Dark theme
+ Barinsta
\ No newline at end of file
diff --git a/app/src/main/res/values/styles.xml b/app/src/main/res/values/styles.xml
index 16f8fce8..5cb01aac 100755
--- a/app/src/main/res/values/styles.xml
+++ b/app/src/main/res/values/styles.xml
@@ -44,7 +44,6 @@
- ?attr/colorPrimary
-
@@ -53,6 +52,10 @@
- @color/white
+
+
diff --git a/app/src/main/res/values/themes.xml b/app/src/main/res/values/themes.xml
index 1bcec347..8026a619 100644
--- a/app/src/main/res/values/themes.xml
+++ b/app/src/main/res/values/themes.xml
@@ -4,7 +4,6 @@
-