diff options
author | Andrei Karas <akaras@inbox.ru> | 2012-09-05 21:48:30 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2012-09-05 21:48:30 +0300 |
commit | 6fee84f3838bdd900e8cfc4a1e4d7f15f35bd6ed (patch) | |
tree | 79a54d4c838c85df29b1b95702b71a95c43ceb5a /src/guichan/widgets/button.cpp | |
parent | d1bb1b375d657f0821ccfebf18fa1c3873314690 (diff) | |
download | manaverse-6fee84f3838bdd900e8cfc4a1e4d7f15f35bd6ed.tar.gz manaverse-6fee84f3838bdd900e8cfc4a1e4d7f15f35bd6ed.tar.bz2 manaverse-6fee84f3838bdd900e8cfc4a1e4d7f15f35bd6ed.tar.xz manaverse-6fee84f3838bdd900e8cfc4a1e4d7f15f35bd6ed.zip |
Improve constructors in some classes.
Diffstat (limited to 'src/guichan/widgets/button.cpp')
-rw-r--r-- | src/guichan/widgets/button.cpp | 34 |
1 files changed, 21 insertions, 13 deletions
diff --git a/src/guichan/widgets/button.cpp b/src/guichan/widgets/button.cpp index f30c890b4..69affd4b7 100644 --- a/src/guichan/widgets/button.cpp +++ b/src/guichan/widgets/button.cpp @@ -59,12 +59,16 @@ namespace gcn { - Button::Button() - : mHasMouse(false), - mKeyPressed(false), - mMousePressed(false), - mAlignment(Graphics::CENTER), - mSpacing(4) + Button::Button() : + Widget(), + MouseListener(), + KeyListener(), + FocusListener(), + mHasMouse(false), + mKeyPressed(false), + mMousePressed(false), + mAlignment(Graphics::CENTER), + mSpacing(4) { setFocusable(true); adjustSize(); @@ -75,13 +79,17 @@ namespace gcn addFocusListener(this); } - Button::Button(const std::string& caption) - : mCaption(caption), - mHasMouse(false), - mKeyPressed(false), - mMousePressed(false), - mAlignment(Graphics::CENTER), - mSpacing(4) + Button::Button(const std::string& caption) : + Widget(), + MouseListener(), + KeyListener(), + FocusListener(), + mCaption(caption), + mHasMouse(false), + mKeyPressed(false), + mMousePressed(false), + mAlignment(Graphics::CENTER), + mSpacing(4) { setFocusable(true); adjustSize(); |