#include <msp/gl/renderer.h>
#include "geometry.h"
#include "inputmethod.h"
+#include "mspgltk_api.h"
#include "partcache.h"
#include "state.h"
/**
Base class for all widgets.
*/
-class Widget
+class MSPGLTK_API Widget
{
friend class Container;
const Geometry &get_geometry() const { return geom; }
void map_coords_to_ancestor(int &, int &, const Widget &) const;
+ void map_coords_to_root(int &, int &) const;
protected:
/** Sets the widget's parent Container. The widget must be unparented when
void set_enabled(bool);
bool is_enabled() const { return !(state&DISABLED); }
- // Deprecated
- void set_focusable(bool);
-
protected:
void set_state(State s) { set_state(s, s); }
void clear_state(State s) { set_state(s, NORMAL); }
virtual bool navigate(Navigation) { return false; }
virtual void animate(const Time::TimeDelta &) { }
protected:
- virtual void on_size_change() { on_geometry_change(); }
+ virtual void on_size_change() { }
virtual void on_style_change() { }
virtual void on_reparent() { }
-
- // Deprecated
- virtual void on_geometry_change() { }
};
} // namespace GLtk