/* $Id$
This file is part of libmspgbase
-Copyright © 2007-2008 Mikko Rasa, Mikkosoft Productions
+Copyright © 2007-2010 Mikko Rasa, Mikkosoft Productions
Distributed under the LGPL
*/
#include <string>
#include <sigc++/signal.h>
+#include "eventsource.h"
namespace Msp {
namespace Graphics {
WindowOptions();
};
-class Window
+class Window: public EventSource
{
public:
struct Private;
struct Event;
- sigc::signal<void, int, int, unsigned, unsigned> signal_button_press;
- sigc::signal<void, int, int, unsigned, unsigned> signal_button_release;
- sigc::signal<void, int, int> signal_pointer_motion;
- sigc::signal<void, unsigned, unsigned, unsigned> signal_key_press;
- sigc::signal<void, unsigned, unsigned> signal_key_release;
- sigc::signal<void, unsigned, unsigned> signal_resize;
sigc::signal<void> signal_close;
protected:
Display &get_display() const { return display; }
const WindowOptions &get_options() const { return options; }
- unsigned get_width() const { return options.width; }
- unsigned get_height() const { return options.height; }
+ virtual unsigned get_width() const { return options.width; }
+ virtual unsigned get_height() const { return options.height; }
const Private &get_private() const { return *priv; }
void show();