From 75906b43ecb9a04fdab365bd8b1a00fbdbc66918 Mon Sep 17 00:00:00 2001 From: Stijn Buys Date: Sun, 3 Oct 2010 19:57:17 +0000 Subject: ui updates, removed impulse and jumpgte g_devel conditions, jumpdrive crash bugfix --- src/ui/widget.h | 34 +++++++++++++++++----------------- 1 file changed, 17 insertions(+), 17 deletions(-) (limited to 'src/ui/widget.h') diff --git a/src/ui/widget.h b/src/ui/widget.h index 8b61bc1..530af05 100644 --- a/src/ui/widget.h +++ b/src/ui/widget.h @@ -57,7 +57,7 @@ public: /** * @see location() */ - inline float left() const { + inline const float left() const { return widget_location.x(); } @@ -66,7 +66,7 @@ public: * @see location() * @see size() */ - inline float right() const { + inline const float right() const { return widget_location.x() + widget_size.width(); } @@ -74,7 +74,7 @@ public: /** * @see location() */ - inline float top() const { + inline const float top() const { return widget_location.y(); } @@ -83,7 +83,7 @@ public: * @see location() * @see size() */ - inline float bottom() const { + inline const float bottom() const { return widget_location.y() + widget_size.height(); } @@ -91,7 +91,7 @@ public: /** * @see size() */ - inline float width() const { + inline const float width() const { return widget_size.width(); } @@ -99,7 +99,7 @@ public: /** * @see size() */ - inline float height() const { + inline const float height() const { return widget_size.height(); } @@ -109,32 +109,32 @@ public: } /// true if this widget will draw a background - inline bool background() const { + inline const bool background() const { return widget_background; } /// true if this widget will draw a border - inline bool border() const { + inline const bool border() const { return widget_border; } /// true if this widget is visible - inline bool visible() const { + inline const bool visible() const { return widget_visible; } /// true if this widget is not visible - inline bool hidden() const { + inline const bool hidden() const { return !widget_visible; } /// true if the widget is enabled - inline bool enabled() const { + inline const bool enabled() const { return widget_enabled; } /// true if the widget is disabled - inline bool disabled() const { + inline const bool disabled() const { return !widget_enabled; } @@ -170,12 +170,12 @@ public: /// set visibility void set_visible(const bool visible = true); - /// disable the widget - virtual void disable(); - - /// enable the widget + /// enable or disable the widget virtual void enable(); - + + /// enable or disable the widget + virtual void disable(); + ///set enabled or disabled state void set_enabled(const bool enabled = true); -- cgit v1.2.3