summaryrefslogtreecommitdiffstats
path: root/app/src/main/java/com/xc3fff0e/xmanager/SplashActivity.java
diff options
context:
space:
mode:
Diffstat (limited to 'app/src/main/java/com/xc3fff0e/xmanager/SplashActivity.java')
-rw-r--r--app/src/main/java/com/xc3fff0e/xmanager/SplashActivity.java45
1 files changed, 45 insertions, 0 deletions
diff --git a/app/src/main/java/com/xc3fff0e/xmanager/SplashActivity.java b/app/src/main/java/com/xc3fff0e/xmanager/SplashActivity.java
index 5e189a5..f022e9f 100644
--- a/app/src/main/java/com/xc3fff0e/xmanager/SplashActivity.java
+++ b/app/src/main/java/com/xc3fff0e/xmanager/SplashActivity.java
@@ -2,8 +2,10 @@ package com.xc3fff0e.xmanager;
import android.animation.*;
import android.app.*;
+import android.app.Activity;
import android.content.*;
import android.content.Intent;
+import android.content.SharedPreferences;
import android.content.res.*;
import android.graphics.*;
import android.graphics.Typeface;
@@ -51,6 +53,7 @@ public class SplashActivity extends AppCompatActivity {
private TimerTask Timer;
private Intent Switch_Activity = new Intent();
+ private SharedPreferences THEME;
@Override
protected void onCreate(Bundle _savedInstanceState) {
@@ -67,6 +70,7 @@ public class SplashActivity extends AppCompatActivity {
main_body = findViewById(R.id.main_body);
icon_splash = findViewById(R.id.icon_splash);
title_splash = findViewById(R.id.title_splash);
+ THEME = getSharedPreferences("THEME", Activity.MODE_PRIVATE);
}
private void initializeLogic() {
@@ -129,6 +133,7 @@ public class SplashActivity extends AppCompatActivity {
_timer.schedule(Timer, (int)(1000));
_Dark_Navigation();
+ _Theme_UI();
}
@Override
@@ -143,6 +148,46 @@ public class SplashActivity extends AppCompatActivity {
}
+ public void _Theme_UI() {
+ if (THEME.getString("THEME", "").equals("14")) {
+ main_body.setBackgroundColor(0xFF1B5E20);
+ }
+ else {
+ if (THEME.getString("THEME", "").equals("15")) {
+ main_body.setBackgroundColor(0xFF00008B);
+ }
+ else {
+ if (THEME.getString("THEME", "").equals("16")) {
+ main_body.setBackgroundColor(0xFF8B0000);
+ }
+ else {
+ if (THEME.getString("THEME", "").equals("17")) {
+ main_body.setBackgroundColor(0xFFFF8C00);
+ }
+ else {
+ if (THEME.getString("THEME", "").equals("18")) {
+ main_body.setBackgroundColor(0xFFAA336A);
+ }
+ else {
+ if (THEME.getString("THEME", "").equals("19")) {
+ main_body.setBackgroundColor(0xFF301934);
+ }
+ else {
+ if (THEME.getString("THEME", "").equals("20")) {
+ main_body.setBackgroundColor(0xFF008B8B);
+ }
+ else {
+ main_body.setBackgroundColor(0xFF171717);
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+ }
+
+
@Deprecated
public void showMessage(String _s) {
Toast.makeText(getApplicationContext(), _s, Toast.LENGTH_SHORT).show();