summaryrefslogtreecommitdiff
path: root/src/gui
diff options
context:
space:
mode:
authorThorbjørn Lindeijer <bjorn@lindeijer.nl>2025-03-14 13:56:57 +0100
committerThorbjørn Lindeijer <bjorn@lindeijer.nl>2025-03-17 13:47:42 +0100
commit4d8a5ed01560cde4e2c3caa819cb165dc7ac3df6 (patch)
tree4dc68e5c517e05ae0c1c89477bced774bdb67016 /src/gui
parent2a8355942f7e4127ac911588c9893b4d6c5a82f8 (diff)
downloadmana-4d8a5ed01560cde4e2c3caa819cb165dc7ac3df6.tar.gz
mana-4d8a5ed01560cde4e2c3caa819cb165dc7ac3df6.tar.bz2
mana-4d8a5ed01560cde4e2c3caa819cb165dc7ac3df6.tar.xz
mana-4d8a5ed01560cde4e2c3caa819cb165dc7ac3df6.zip
Don't call static ResourceManager methods through instance
Diffstat (limited to 'src/gui')
-rw-r--r--src/gui/gui.cpp8
1 files changed, 3 insertions, 5 deletions
diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp
index 90f12672..f9a36472 100644
--- a/src/gui/gui.cpp
+++ b/src/gui/gui.cpp
@@ -80,12 +80,10 @@ Gui::Gui(Graphics *graphics, const std::string &themePath)
Window::setWindowContainer(guiTop);
setTop(guiTop);
- ResourceManager *resman = ResourceManager::getInstance();
-
// Set global font
const int fontSize = config.fontSize;
std::string fontFile = branding.getValue("font", "fonts/dejavusans.ttf");
- std::string path = resman->getPath(fontFile);
+ std::string path = ResourceManager::getPath(fontFile);
// Initialize the font scale before creating the fonts
TrueTypeFont::updateFontScale(graphics->getScale());
@@ -103,7 +101,7 @@ Gui::Gui(Graphics *graphics, const std::string &themePath)
// Set bold font
fontFile = branding.getValue("boldFont", "fonts/dejavusans-bold.ttf");
- path = resman->getPath(fontFile);
+ path = ResourceManager::getPath(fontFile);
try
{
boldFont = new TrueTypeFont(path, fontSize);
@@ -116,7 +114,7 @@ Gui::Gui(Graphics *graphics, const std::string &themePath)
// Set mono font
fontFile = branding.getValue("monoFont", "fonts/dejavusans-mono.ttf");
- path = resman->getPath(fontFile);
+ path = ResourceManager::getPath(fontFile);
try
{
monoFont = new TrueTypeFont(path, fontSize);