X-Git-Url: http://git.tdb.fi/?a=blobdiff_plain;f=source%2Finput%2Fmouse.h;h=0f0013c3964417ecd11b9181945c0aeb9525ad57;hb=d7686e3867e3c68cec0d3767a21f9d2408383085;hp=5f7e71478913902c598bdeb551ea59d159c3a00a;hpb=1023b38fa278cea71fba3d2881e1bfde930cd025;p=libs%2Fgui.git diff --git a/source/input/mouse.h b/source/input/mouse.h index 5f7e714..0f0013c 100644 --- a/source/input/mouse.h +++ b/source/input/mouse.h @@ -1,6 +1,8 @@ #ifndef MSP_INPUT_MOUSE_H_ #define MSP_INPUT_MOUSE_H_ +#include +#include #include #include "device.h" @@ -13,19 +15,18 @@ uniform way. Note: Y axis grows upwards. */ -class Mouse: public Device +class MSPGUI_API Mouse: public Device, public sigc::trackable { private: - Graphics::EventSource &source; + Graphics::Window &window; public: - Mouse(Graphics::EventSource &); - virtual std::string get_button_name(unsigned) const; - virtual std::string get_axis_name(unsigned) const; + Mouse(Graphics::Window &); + + std::string get_button_name(unsigned) const override; + std::string get_axis_name(unsigned) const override; private: - void button_press(int, int, unsigned, unsigned); - void button_release(int, int, unsigned, unsigned); - void pointer_motion(int, int); + void input_event(const Graphics::Window::Event &); }; } // namespace Input