From 1eda598ab8d34e8d2fd3ecf990fcb64d49f518f8 Mon Sep 17 00:00:00 2001 From: Maximilian Philipps Date: Sun, 2 Aug 2009 20:15:38 +0200 Subject: patch for #813, adds mouse over highlight for radio buttons, tabs, checkboxes, slider and scrollbars --- src/gui/widgets/radiobutton.h | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'src/gui/widgets/radiobutton.h') diff --git a/src/gui/widgets/radiobutton.h b/src/gui/widgets/radiobutton.h index 9aec3add..57eb3623 100644 --- a/src/gui/widgets/radiobutton.h +++ b/src/gui/widgets/radiobutton.h @@ -26,13 +26,13 @@ class Image; -/* +/** * Guichan based RadioButton with custom look */ class RadioButton : public gcn::RadioButton { public: - /* + /** * Constructor. */ RadioButton(const std::string &caption,const std::string &group, @@ -54,13 +54,26 @@ class RadioButton : public gcn::RadioButton */ void draw(gcn::Graphics* graphics); + /** + * Called when the mouse enteres the widget area. + */ + void mouseEntered(gcn::MouseEvent& event); + + /** + * Called when the mouse leaves the widget area. + */ + void mouseExited(gcn::MouseEvent& event); + private: static int instances; static float mAlpha; + bool mHasMouse; static Image *radioNormal; static Image *radioChecked; static Image *radioDisabled; static Image *radioDisabledChecked; + static Image *radioNormalHi; + static Image *radioCheckedHi; }; #endif /* RADIOBUTTON_H */ -- cgit v1.2.3-70-g09d2