diff options
author | Björn Steinbrink <B.Steinbrink@gmx.de> | 2005-08-28 17:41:05 +0000 |
---|---|---|
committer | Björn Steinbrink <B.Steinbrink@gmx.de> | 2005-08-28 17:41:05 +0000 |
commit | b05cbc7df24019efd9b2d1dae046c4cf6eed2390 (patch) | |
tree | 3dfc1fc9a400b62c32ca1bd3c347e8d711370c1c /src/gui/window.h | |
parent | 00a698fe8b1babdc323842ee497107d9ed278ebc (diff) | |
download | mana-b05cbc7df24019efd9b2d1dae046c4cf6eed2390.tar.gz mana-b05cbc7df24019efd9b2d1dae046c4cf6eed2390.tar.bz2 mana-b05cbc7df24019efd9b2d1dae046c4cf6eed2390.tar.xz mana-b05cbc7df24019efd9b2d1dae046c4cf6eed2390.zip |
Create a static ConfigListener for the Window class.
Diffstat (limited to 'src/gui/window.h')
-rw-r--r-- | src/gui/window.h | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/src/gui/window.h b/src/gui/window.h index 18da6cdb..d8717f3c 100644 --- a/src/gui/window.h +++ b/src/gui/window.h @@ -27,11 +27,11 @@ #include <guichan/widgets/window.hpp> #include <guichan/rectangle.hpp> -#include "../configlistener.h" #include "../guichanfwd.h" #include "../resources/image.h" +class ConfigListener; class ImageRect; class WindowContainer; @@ -41,9 +41,11 @@ class WindowContainer; * * \ingroup GUI */ -class Window : public gcn::Window, public ConfigListener +class Window : public gcn::Window { public: + friend class WindowConfigListener; + /** * Constructor. Initializes the title to the given text and hooks * itself into the window container. @@ -154,11 +156,6 @@ class Window : public gcn::Window, public ConfigListener void mouseRelease(int x, int y, int button); /** - * Called when an config option changes. - */ - void optionChanged(const std::string &name); - - /** * The position of the resize grip */ gcn::Rectangle getGripDimension(); @@ -181,6 +178,12 @@ class Window : public gcn::Window, public ConfigListener /** The window container windows add themselves to. */ static WindowContainer* windowContainer; + /** + * The config listener that listens to changes relevant to all + * windows + */ + static ConfigListener *windowConfigListener; + static int instances; /**< Number of Window instances */ static ImageRect border; /**< The window border and background */ static Image *resizeGrip; /**< The grip to resize window */ |