added namespace GUI

svn-id: r11255
This commit is contained in:
Max Horn 2003-11-10 23:40:48 +00:00
parent 5c2a3da7f2
commit 22c22d1e81
37 changed files with 166 additions and 44 deletions

View file

@ -25,6 +25,8 @@
#include "gui/newgui.h"
namespace GUI {
Widget::Widget(GuiObject *boss, int x, int y, int w, int h)
: GuiObject(x, y, w, h), _type(0), _boss(boss),
_id(0), _flags(0), _hasFocus(false) {
@ -260,3 +262,5 @@ int SliderWidget::valueToPos(int value) {
int SliderWidget::posToValue(int pos) {
return (pos) * (_valueMax - _valueMin) / (_w - _labelWidth - 4) + _valueMin;
}
} // End of namespace GUI