aboutsummaryrefslogtreecommitdiff
path: root/src/Theme.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/Theme.cpp')
-rw-r--r--src/Theme.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/Theme.cpp b/src/Theme.cpp
index 18581ff..a197848 100644
--- a/src/Theme.cpp
+++ b/src/Theme.cpp
@@ -1,4 +1,5 @@
#include "../include/Theme.hpp"
+#include "../include/Config.hpp"
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
@@ -76,10 +77,7 @@ namespace QuickMedia {
init_theme_dark();
init_theme_nord();
- char *theme = getenv("QM_THEME");
- if(!theme)
- return;
-
+ const char *theme = get_config().theme.c_str();
if(strcmp(theme, "default") == 0)
current_theme = THEME_DARK;
else if(strcmp(theme, "nord") == 0)
@@ -92,7 +90,7 @@ namespace QuickMedia {
current_theme = theme;
}
- Theme& get_current_theme() {
+ const Theme& get_current_theme() {
assert(themes_initialized);
return themes[current_theme];
}