--- a/src/widget/widget_button.cpp Tue Feb 27 13:26:47 2007 +0000
+++ b/src/widget/widget_button.cpp Tue Feb 27 22:47:59 2007 +0000
@@ -15,5 +15,22 @@
#include "../table/sprites.h"
#include "../genworld.h"
#include "../helpers.hpp"
+#include "window_events.hpp"
+
+namespace gui {
+
+/*virtual*/ void Button::DrawBackground(EvtPaint &ev)
+{
+ DrawFrameRect(m_color, m_pushed ? FR_LOWERED : FR_NONE);
+}
+
+/*virtual*/ void Button::OnLeftClick(EvtClick &ev)
+{
+ m_pushed = !m_pushed;
+ CallHandlers(ev);
+ ev.SetHandled();
+ Invalidate();
+}
+}; // namespace gui