mirror of
https://github.com/plan-player-analytics/Plan.git
synced 2025-01-25 09:32:11 +01:00
Removed use of EnumUtility
This commit is contained in:
parent
6fc7185669
commit
f324541343
@ -9,12 +9,12 @@ import com.djrapitops.plan.api.exceptions.EnableException;
|
|||||||
import com.djrapitops.plan.system.SubSystem;
|
import com.djrapitops.plan.system.SubSystem;
|
||||||
import com.djrapitops.plan.system.settings.Settings;
|
import com.djrapitops.plan.system.settings.Settings;
|
||||||
import com.djrapitops.plan.system.settings.config.ConfigSystem;
|
import com.djrapitops.plan.system.settings.config.ConfigSystem;
|
||||||
import com.djrapitops.plugin.api.utility.EnumUtility;
|
|
||||||
import com.djrapitops.plugin.api.utility.log.Log;
|
import com.djrapitops.plugin.api.utility.log.Log;
|
||||||
import com.djrapitops.plugin.utilities.Verify;
|
import com.djrapitops.plugin.utilities.Verify;
|
||||||
|
|
||||||
import java.io.IOException;
|
import java.io.IOException;
|
||||||
import java.util.List;
|
|
||||||
|
import static com.djrapitops.plan.system.settings.theme.ThemeVal.*;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Enum that contains available themes.
|
* Enum that contains available themes.
|
||||||
@ -82,12 +82,14 @@ public class Theme implements SubSystem {
|
|||||||
|
|
||||||
public String replaceThemeColors(String resourceString) {
|
public String replaceThemeColors(String resourceString) {
|
||||||
String replaced = resourceString;
|
String replaced = resourceString;
|
||||||
List<ThemeVal> themeVariables = EnumUtility.getSupportedEnumValues(ThemeVal.class, "RED", "PINK", "PURPLE",
|
ThemeVal[] themeVariables = new ThemeVal[]{
|
||||||
"DEEP_PURPLE", "INDIGO", "BLUE", "LIGHT_BLUE", "CYAN", "TEAL", "GREEN", "LIGHT_GREEN", "LIME",
|
RED, PINK, PURPLE,
|
||||||
"YELLOW", "AMBER", "ORANGE", "DEEP_ORANGE", "BROWN", "GREY", "BLUE_GREY", "BLACK", "WHITE",
|
DEEP_PURPLE, INDIGO, BLUE, LIGHT_BLUE, CYAN, TEAL, GREEN, LIGHT_GREEN, LIME,
|
||||||
"GRAPH_PUNCHCARD", "GRAPH_PLAYERS_ONLINE", "GRAPH_TPS_HIGH", "GRAPH_TPS_MED", "GRAPH_TPS_LOW",
|
YELLOW, AMBER, ORANGE, DEEP_ORANGE, BROWN, GREY, BLUE_GREY, BLACK, WHITE,
|
||||||
"GRAPH_CPU", "GRAPH_RAM", "GRAPH_CHUNKS", "GRAPH_ENTITIES", "GRAPH_WORLD_PIE", "GRAPH_GM_PIE",
|
GRAPH_PUNCHCARD, GRAPH_PLAYERS_ONLINE, GRAPH_TPS_HIGH, GRAPH_TPS_MED, GRAPH_TPS_LOW,
|
||||||
"GRAPH_ACTIVITY_PIE", "GRAPH_SERVER_PREF_PIE", "FONT_STYLESHEET", "FONT_FAMILY");
|
GRAPH_CPU, GRAPH_RAM, GRAPH_CHUNKS, GRAPH_ENTITIES, GRAPH_WORLD_PIE, GRAPH_GM_PIE,
|
||||||
|
GRAPH_ACTIVITY_PIE, GRAPH_SERVER_PREF_PIE, FONT_STYLESHEET, FONT_FAMILY
|
||||||
|
};
|
||||||
for (ThemeVal variable : themeVariables) {
|
for (ThemeVal variable : themeVariables) {
|
||||||
String value = getColor(variable);
|
String value = getColor(variable);
|
||||||
String defaultValue = variable.getDefaultValue();
|
String defaultValue = variable.getDefaultValue();
|
||||||
|
Loading…
Reference in New Issue
Block a user