From 95445bb5a7fa0c61e489d2f518cd3ebfd35c4fba Mon Sep 17 00:00:00 2001 From: Andrei Karas Date: Tue, 13 May 2014 23:38:08 +0300 Subject: Move guiconfiglistener into separate file. --- src/gui/gui.cpp | 28 +--------------------------- 1 file changed, 1 insertion(+), 27 deletions(-) (limited to 'src/gui') diff --git a/src/gui/gui.cpp b/src/gui/gui.cpp index 7c17b5991..2841a5369 100644 --- a/src/gui/gui.cpp +++ b/src/gui/gui.cpp @@ -82,6 +82,7 @@ #include "events/keyevent.h" #include "listeners/focuslistener.h" +#include "listeners/guiconfiglistener.h" #include "listeners/keylistener.h" #include "listeners/mouselistener.h" @@ -108,33 +109,6 @@ SDLInput *guiInput = nullptr; // Bolded font Font *boldFont = nullptr; -class GuiConfigListener final : public ConfigListener -{ - public: - explicit GuiConfigListener(Gui *const g): - mGui(g) - {} - - A_DELETE_COPY(GuiConfigListener) - - virtual ~GuiConfigListener() - { - CHECKLISTENERS - } - - void optionChanged(const std::string &name) - { - if (!mGui) - return; - if (name == "customcursor") - mGui->setUseCustomCursor(config.getBoolValue("customcursor")); - else if (name == "doubleClick") - mGui->setDoubleClick(config.getBoolValue("doubleClick")); - } - private: - Gui *mGui; -}; - Gui::Gui() : mTop(nullptr), mGraphics(nullptr), -- cgit v1.2.3-70-g09d2