// constructor MGuiSlide::MGuiSlide(MVector2 position, MVector2 scale, MVector4 color, void (* pointerEvent)(MGuiSlide * slide, MGuiEvent * guiEvent)): m_value(0), m_minValue(0), m_maxValue(1) { m_button.setPosition(position); m_button.setScale(scale); setDirection(MVector2(10, 0)); setParentWindow(NULL); setPosition(position); setScale(getDirection() + scale); setNormalColor(color); setHighLightColor(color); setPressedColor(color); setPointerEvent(pointerEvent); }
//constructor MGuiEditText::MGuiEditText(const char * text, const MVector2 & position, float size, const MVector4 & color, void (* pointerEvent)(MGuiEditText * editText, MGuiEvent * guiEvent)): m_charId(0), m_startSelectionId(0), m_endSelectionId(0), m_limitLength(false), m_maxLength(0), m_isSingleLine(false) { setParentWindow(NULL); setText(text); setPosition(position); setTextSize(size); setNormalColor(color); setHighLightColor(color); setPressedColor(color); setPointerEvent(pointerEvent); autoScaleFromText(); }