Changed Recti as Rect.

Removed eeAABB in favor of Rectf.
Implemented UIScrollView XML load.

--HG--
branch : dev
This commit is contained in:
Martín Lucas Golini
2017-04-16 15:28:36 -03:00
parent 80720302ea
commit 9cf73262f4
67 changed files with 255 additions and 224 deletions

View File

@@ -13,7 +13,7 @@ class EE_API Glyph {
Float advance; ///< Offset to move horizontally to the next character
Rectf bounds; ///< Bounding rectangle of the glyph, in coordinates relative to the baseline
Recti textureRect; ///< Texture coordinates of the glyph inside the font's texture
Rect textureRect; ///< Texture coordinates of the glyph inside the font's texture
};
/** @brief Font interface class. */

View File

@@ -73,7 +73,7 @@ class EE_API FontTrueType : public Font {
Glyph loadGlyph(Uint32 codePoint, unsigned int characterSize, bool bold, Float outlineThickness) const;
Recti findGlyphRect(Page& page, unsigned int width, unsigned int height) const;
Rect findGlyphRect(Page& page, unsigned int width, unsigned int height) const;
bool setCurrentSize(unsigned int characterSize) const;

View File

@@ -157,7 +157,7 @@ class EE_API Image {
Graphics::Image * thumbnail( const Uint32& maxWidth, const Uint32& maxHeight, EE_RESAMPLER_FILTER filter = RESAMPLER_LANCZOS4 );
/** Creates a cropped image from the current image */
Graphics::Image * crop( Recti rect );
Graphics::Image * crop( Rect rect );
/** Set as true if you dont want to free the image data in the Image destruction ( false as default ). */
void avoidFreeImage( const bool& AvoidFree );

View File

@@ -55,9 +55,9 @@ class EE_API PixelDensity {
static Sizei pxToDpI( Sizei size );
static Recti dpToPxI( Recti size);
static Rect dpToPxI( Rect size);
static Recti pxToDpI( Recti size );
static Rect pxToDpI( Rect size );
static Rectf dpToPx( Rectf size);

View File

@@ -84,7 +84,7 @@ class EE_API ScrollParallax {
Vector2f mPos;
Vector2f mSpeed;
Sizef mSize;
Recti mRect;
Rect mRect;
Clock mElapsed;
Vector2i mTiles;
Rectf mAABB;

View File

@@ -45,7 +45,7 @@ class EE_API Sprite : public Drawable {
* @param Offset The offset added to the position of the frame ( the SubTexture )
* @param TexSector The sector of the texture used by the SubTexture to be rendered
*/
Sprite( const Uint32& TexId, const Sizef &DestSize = Sizef(0,0), const Vector2i &offset = Vector2i(0,0), const Recti& TexSector = Recti(0,0,0,0) );
Sprite( const Uint32& TexId, const Sizef &DestSize = Sizef(0,0), const Vector2i &offset = Vector2i(0,0), const Rect& TexSector = Rect(0,0,0,0) );
virtual ~Sprite();
@@ -148,7 +148,7 @@ class EE_API Sprite : public Drawable {
void reset();
/** @return The AABB (axis-aligned bounding box) */
eeAABB getAABB();
Rectf getAABB();
/** Update the colors of every vertex rendered of the sprite ( this will override the default color )
* @param Color0 The Left - Top vertex color
@@ -174,7 +174,7 @@ class EE_API Sprite : public Drawable {
* @param TexSector The texture sector to be rendered ( default all the texture )
* @return True if success
*/
bool createStatic(const Uint32& TexId, const Sizef &DestSize = Sizef(0,0), const Vector2i &offset = Vector2i(0,0), const Recti& TexSector = Recti(0,0,0,0) );
bool createStatic(const Uint32& TexId, const Sizef &DestSize = Sizef(0,0), const Vector2i &offset = Vector2i(0,0), const Rect& TexSector = Rect(0,0,0,0) );
/** Creates an animated sprite
* @param SubFramesNum The number of subframes of the sprite
@@ -188,7 +188,7 @@ class EE_API Sprite : public Drawable {
* @param TexSector The texture sector to be rendered ( default all the texture )
* @return The frame position or 0 if fails
*/
unsigned int addFrame( const Uint32& TexId, const Sizef& DestSize = Sizef(0,0), const Vector2i& offset = Vector2i(0,0), const Recti& TexSector = Recti(0,0,0,0) );
unsigned int addFrame( const Uint32& TexId, const Sizef& DestSize = Sizef(0,0), const Vector2i& offset = Vector2i(0,0), const Rect& TexSector = Rect(0,0,0,0) );
/** Add a frame to the sprite (on the current sub frame)
* @param SubTexture The SubTexture used in the frame
@@ -215,7 +215,7 @@ class EE_API Sprite : public Drawable {
* @param TexSector The texture sector to be rendered ( default all the texture )
* @return True if success
*/
bool addSubFrame( const Uint32& TexId, const unsigned int& NumFrame, const unsigned int& NumSubFrame, const Sizef& DestSize = Sizef(0,0), const Vector2i& offset = Vector2i(0,0), const Recti& TexSector = Recti(0,0,0,0) );
bool addSubFrame( const Uint32& TexId, const unsigned int& NumFrame, const unsigned int& NumSubFrame, const Sizef& DestSize = Sizef(0,0), const Vector2i& offset = Vector2i(0,0), const Rect& TexSector = Rect(0,0,0,0) );
/** Add a frame on an specific subframe to the sprite
* @param SubTexture The SubTexture used in the frame

View File

@@ -25,7 +25,7 @@ class EE_API SubTexture : public Drawable {
* @param SrcRect The texture part that will be used as the SubTexture.
* @param Name The texture name ( if any )
*/
SubTexture( const Uint32& TexId, const Recti& srcRect, const std::string& getName = "" );
SubTexture( const Uint32& TexId, const Rect& srcRect, const std::string& getName = "" );
/** Creates a SubTexture of the indicated part of the texture.
* @param TexId The texture id
@@ -33,7 +33,7 @@ class EE_API SubTexture : public Drawable {
* @param DestSize The destination size that the SubTexture will have when rendered.
* @param Name The texture name ( if any )
*/
SubTexture( const Uint32& TexId, const Recti& srcRect, const Sizef& destSize, const std::string& getName = "" );
SubTexture( const Uint32& TexId, const Rect& srcRect, const Sizef& destSize, const std::string& getName = "" );
/** Creates a SubTexture of the indicated part of the texture.
* @param TexId The texture id
@@ -42,7 +42,7 @@ class EE_API SubTexture : public Drawable {
* @param Offset The offset that will be added to the position passed when any Draw call is used.
* @param Name The texture name ( if any )
*/
SubTexture( const Uint32& TexId, const Recti& srcRect, const Sizef& destSize, const Vector2i& offset, const std::string& getName = "" );
SubTexture( const Uint32& TexId, const Rect& srcRect, const Sizef& destSize, const Vector2i& offset, const std::string& getName = "" );
virtual ~SubTexture();
@@ -62,10 +62,10 @@ class EE_API SubTexture : public Drawable {
void setTextureId( const Uint32& TexId );
/** @return The Texture sector that represents the SubTexture */
const Recti& getSrcRect() const;
const Rect& getSrcRect() const;
/** Sets the Texture sector that represents the SubTexture */
void setSrcRect( const Recti& Rect );
void setSrcRect( const Rect& rect );
/** @return The Destination Size of the SubTexture. */
const Sizef& getDestSize() const;
@@ -169,7 +169,7 @@ class EE_API SubTexture : public Drawable {
Uint32 mId;
Uint32 mTexId;
Graphics::Texture * mTexture;
Recti mSrcRect;
Rect mSrcRect;
Sizef mOriDestSize;
Sizef mDestSize;
Vector2i mOffset;

View File

@@ -171,7 +171,7 @@ class EE_API Texture : public Image, public Drawable, private NonCopyable {
* @param Center The rotation and scaling center. The center point is relative to the top-left corner of the object.
* @param texSector The texture sector to render. You can render only a part of the texture. ( default render all the texture )
*/
void draw( const Float &x, const Float &y, const Float &Angle = 0, const Vector2f &scale = Vector2f::One, const Color& Color = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, const EE_RENDER_MODE &Effect = RN_NORMAL, OriginPoint Center = OriginPoint(OriginPoint::OriginCenter), const Recti& texSector = Recti(0,0,0,0) );
void draw( const Float &x, const Float &y, const Float &Angle = 0, const Vector2f &scale = Vector2f::One, const Color& Color = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, const EE_RENDER_MODE &Effect = RN_NORMAL, OriginPoint Center = OriginPoint(OriginPoint::OriginCenter), const Rect& texSector = Rect(0,0,0,0) );
/** Render the texture on screen. Extended because can set the vertex colors individually
* @param x The x position on screen
@@ -189,7 +189,7 @@ class EE_API Texture : public Image, public Drawable, private NonCopyable {
* @param Center The rotation and scaling center. The center point is relative to the top-left corner of the object.
* @param texSector The texture sector to render. You can render only a part of the texture. ( default render all the texture )
*/
void drawEx( Float x, Float y, Float width = 0.0f, Float height = 0.0f, const Float &Angle = 0, const Vector2f &scale = Vector2f::One, const Color& Color0 = Color(255,255,255,255), const Color& Color1 = Color(255,255,255,255), const Color& Color2 = Color(255,255,255,255), const Color& Color3 = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, const EE_RENDER_MODE &Effect = RN_NORMAL, OriginPoint Center = OriginPoint(OriginPoint::OriginCenter), const Recti& texSector = Recti(0,0,0,0) );
void drawEx( Float x, Float y, Float width = 0.0f, Float height = 0.0f, const Float &Angle = 0, const Vector2f &scale = Vector2f::One, const Color& Color0 = Color(255,255,255,255), const Color& Color1 = Color(255,255,255,255), const Color& Color2 = Color(255,255,255,255), const Color& Color3 = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, const EE_RENDER_MODE &Effect = RN_NORMAL, OriginPoint Center = OriginPoint(OriginPoint::OriginCenter), const Rect& texSector = Rect(0,0,0,0) );
/** Render a quad on Screen
* @param Q The Quad2f
@@ -200,7 +200,7 @@ class EE_API Texture : public Image, public Drawable, private NonCopyable {
* @param Blend Set the Blend Mode ( default ALPHA_NORMAL )
* @param texSector The texture sector to render. You can render only a part of the texture. ( default render all the texture )
*/
void drawQuad( const Quad2f& Q, const Vector2f& Offset = Vector2f(), const Float &Angle = 0.0f, const Vector2f &scale = Vector2f::One, const Color& Color = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, const Recti& texSector = Recti(0,0,0,0) );
void drawQuad( const Quad2f& Q, const Vector2f& Offset = Vector2f(), const Float &Angle = 0.0f, const Vector2f &scale = Vector2f::One, const Color& Color = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, const Rect& texSector = Rect(0,0,0,0) );
/** Render a quad on Screen
* @param Q The Quad2f
@@ -214,7 +214,7 @@ class EE_API Texture : public Image, public Drawable, private NonCopyable {
* @param Blend Set the Blend Mode ( default ALPHA_NORMAL )
* @param texSector The texture sector to render. You can render only a part of the texture. ( default render all the texture )
*/
void drawQuadEx( Quad2f Q, const Vector2f& Offset = Vector2f(), const Float &Angle = 0.0f, const Vector2f &scale = Vector2f::One, const Color& Color0 = Color(255,255,255,255), const Color& Color1 = Color(255,255,255,255), const Color& Color2 = Color(255,255,255,255), const Color& Color3 = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, Recti texSector = Recti(0,0,0,0) );
void drawQuadEx( Quad2f Q, const Vector2f& Offset = Vector2f(), const Float &Angle = 0.0f, const Vector2f &scale = Vector2f::One, const Color& Color0 = Color(255,255,255,255), const Color& Color1 = Color(255,255,255,255), const Color& Color2 = Color(255,255,255,255), const Color& Color3 = Color(255,255,255,255), const EE_BLEND_MODE &Blend = ALPHA_NORMAL, Rect texSector = Rect(0,0,0,0) );
Sizef getSize();

View File

@@ -30,7 +30,7 @@ class EE_API TextureAtlas : public ResourceManager<SubTexture> {
* @param SrcRect The texture part that will be used as the SubTexture.
* @param Name The texture name ( if any )
*/
SubTexture * add( const Uint32& TexId, const Recti& SrcRect, const std::string& getName = "" );
SubTexture * add( const Uint32& TexId, const Rect& SrcRect, const std::string& getName = "" );
/** Creates and add to the texture atlas a SubTexture of the indicated part of the texture.
* @param TexId The texture id
@@ -38,7 +38,7 @@ class EE_API TextureAtlas : public ResourceManager<SubTexture> {
* @param DestSize The destination size that the SubTexture will have when rendered.
* @param Name The texture name ( if any )
*/
SubTexture * add( const Uint32& TexId, const Recti& SrcRect, const Sizef& DestSize, const std::string& getName = "" );
SubTexture * add( const Uint32& TexId, const Rect& SrcRect, const Sizef& DestSize, const std::string& getName = "" );
/** Creates and add to the texture atlas a SubTexture of the indicated part of the texture.
* @param TexId The texture id
@@ -47,7 +47,7 @@ class EE_API TextureAtlas : public ResourceManager<SubTexture> {
* @param Offset The offset that will be added to the position passed when any Draw call is used.
* @param Name The texture name ( if any )
*/
SubTexture * add( const Uint32& TexId, const Recti& SrcRect, const Sizef& DestSize, const Vector2i& Offset, const std::string& getName = "" );
SubTexture * add( const Uint32& TexId, const Rect& SrcRect, const Sizef& DestSize, const Vector2i& Offset, const std::string& getName = "" );
/** @return The texture atlas name. */
const std::string& getName() const;

View File

@@ -35,7 +35,7 @@ class EE_API MapLight {
void updatePos( const Vector2f& newPos );
eeAABB getAABB() const;
Rectf getAABB() const;
const Float& getRadius() const;
@@ -61,7 +61,7 @@ class EE_API MapLight {
Vector2f mPos;
RGB mColor;
LIGHT_TYPE mType;
eeAABB mAABB;
Rectf mAABB;
bool mActive;
void updateAABB();

View File

@@ -172,7 +172,7 @@ class EE_API TileMap {
const Color& getBaseColor() const;
const eeAABB& getViewAreaAABB() const;
const Rectf& getViewAreaAABB() const;
MapLightManager * getLightManager() const;
@@ -265,7 +265,7 @@ class EE_API TileMap {
GOTypesList mObjTypes;
CreateGOCb mCreateGOCb;
Texture * mTileTex;
eeAABB mScreenAABB;
Rectf mScreenAABB;
MapLightManager * mLightManager;
MapDrawCb mDrawCb;
MapUpdateCb mUpdateCb;

View File

@@ -19,21 +19,21 @@ class tRECT {
tRECT<T> copy();
bool intersect( const tRECT<T>& Rect );
bool intersect( const tRECT<T>& rect );
bool contains( const tRECT<T>& Rect );
bool contains( const tRECT<T>& rect );
bool contains( const Vector2<T>& Vect );
void expand( const tRECT<T>& Rect );
void expand( const tRECT<T>& rect );
void shrink( const tRECT<T>& Rect );
void shrink( const tRECT<T>& rect );
void expand( const Vector2<T>& Vect );
T area();
T mergedArea( const tRECT<T>& Rect );
T mergedArea( const tRECT<T>& rect );
bool intersectsSegment( const Vector2<T>& a, const Vector2<T>& b );
@@ -176,13 +176,13 @@ template <typename T>
tRECT<T>::tRECT() : Left(0), Right(0), Top(0), Bottom(0) {}
template <typename T>
bool tRECT<T>::contains( const tRECT<T>& Rect ) {
return ( Left <= Rect.Left && Right >= Rect.Right && Top <= Rect.Top && Bottom >= Rect.Bottom );
bool tRECT<T>::contains( const tRECT<T>& rect ) {
return ( Left <= rect.Left && Right >= rect.Right && Top <= rect.Top && Bottom >= rect.Bottom );
}
template <typename T>
bool tRECT<T>::intersect( const tRECT<T>& Rect ) {
return !( Left > Rect.Right || Right < Rect.Left || Top > Rect.Bottom || Bottom < Rect.Top );
bool tRECT<T>::intersect( const tRECT<T>& rect ) {
return !( Left > rect.Right || Right < rect.Left || Top > rect.Bottom || Bottom < rect.Top );
}
template <typename T>
@@ -216,19 +216,19 @@ T tRECT<T>::getHeight() {
}
template <typename T>
void tRECT<T>::expand( const tRECT<T>& Rect ) {
Left = eemin( Left , Rect.Left );
Bottom = eemax( Bottom , Rect.Bottom );
Right = eemax( Right , Rect.Right );
Top = eemin( Top , Rect.Top );
void tRECT<T>::expand( const tRECT<T>& rect ) {
Left = eemin( Left , rect.Left );
Bottom = eemax( Bottom , rect.Bottom );
Right = eemax( Right , rect.Right );
Top = eemin( Top , rect.Top );
}
template <typename T>
void tRECT<T>::shrink( const tRECT<T>& Rect ) {
Left = eemax( Left , Rect.Left );
Top = eemax( Top , Rect.Top );
Right = eemax( Left, eemin( Right , Rect.Right ) );
Bottom = eemax( Top, eemin( Bottom , Rect.Bottom ) );
void tRECT<T>::shrink( const tRECT<T>& rect ) {
Left = eemax( Left , rect.Left );
Top = eemax( Top , rect.Top );
Right = eemax( Left, eemin( Right , rect.Right ) );
Bottom = eemax( Top, eemin( Bottom , rect.Bottom ) );
}
template <typename T>
@@ -245,8 +245,8 @@ T tRECT<T>::area() {
}
template <typename T>
T tRECT<T>::mergedArea( const tRECT<T>& Rect ) {
return ( eemax( Right, Rect.Right ) - eemin( Left, Rect.Left ) ) * ( eemin( Bottom, Rect.Bottom ) - eemax( Top, Rect.Top ) );
T tRECT<T>::mergedArea( const tRECT<T>& rect ) {
return ( eemax( Right, rect.Right ) - eemin( Left, rect.Left ) ) * ( eemin( Bottom, rect.Bottom ) - eemax( Top, rect.Top ) );
}
template <typename T>
@@ -341,9 +341,7 @@ void tRECT<T>::scale( Vector2<T> scale ) {
typedef tRECT<unsigned int> Rectu;
typedef tRECT<Float> Rectf;
typedef tRECT<Float> eeAABB; // Axis-Aligned Bounding Box
typedef tRECT<int> Recti;
typedef tRECT<Int32> Rect;
typedef tRECT<int> Rect;
}}

View File

@@ -68,7 +68,7 @@ class EE_API UIControl {
const Sizei& getRealSize();
Recti getRect() const;
Rect getRect() const;
UIControl * setVisible( const bool& visible );
@@ -223,7 +223,7 @@ class EE_API UIControl {
void applyDefaultTheme();
Recti getScreenRect();
Rect getScreenRect();
void childsCloseAll();
@@ -400,7 +400,7 @@ class EE_API UIControl {
Time getElapsed();
Recti makePadding( bool PadLeft = true, bool PadRight = true, bool PadTop = true, bool PadBottom = true, bool SkipFlags = false );
Rect makePadding( bool PadLeft = true, bool PadRight = true, bool PadTop = true, bool PadBottom = true, bool SkipFlags = false );
Sizei getSkinSize( UISkin * Skin, const Uint32& State = UISkinState::StateNormal );

View File

@@ -77,9 +77,9 @@ class EE_API UIListBox : public UITouchDragableWidget {
Graphics::Font * getFont() const;
void setContainerPadding( const Recti& Padding );
void setContainerPadding( const Rect& Padding );
const Recti& getContainerPadding() const;
const Rect& getContainerPadding() const;
void setSmoothScroll( const bool& soft );
@@ -121,9 +121,9 @@ class EE_API UIListBox : public UITouchDragableWidget {
Uint32 mRowHeight;
UI_SCROLLBAR_MODE mVScrollMode;
UI_SCROLLBAR_MODE mHScrollMode;
Recti mContainerPadding;
Recti mHScrollPadding;
Recti mVScrollPadding;
Rect mContainerPadding;
Rect mHScrollPadding;
Rect mVScrollPadding;
UIItemContainer<UIListBox> * mContainer;
UIScrollBar * mVScrollBar;
UIScrollBar * mHScrollBar;

View File

@@ -58,7 +58,7 @@ class EE_API UIMenu : public UIWidget {
virtual bool hide();
const Recti& getPadding() const;
const Rect& getPadding() const;
Uint32 getMinRightMargin() const;

View File

@@ -29,9 +29,9 @@ class EE_API UIPushButton : public UIWidget {
virtual const String& getText();
void setPadding( const Recti& padding );
void setPadding( const Rect& padding );
const Recti& getPadding() const;
const Rect& getPadding() const;
void setIconHorizontalMargin( Int32 margin );

View File

@@ -39,6 +39,8 @@ class EE_API UIScrollView : public UITouchDragableWidget {
UIScrollBar * getHorizontalScrollBar() const;
UIControlAnim * getContainer() const;
virtual void loadFromXmlNode( const pugi::xml_node& node );
protected:
ScrollViewType mViewType;
UI_SCROLLBAR_MODE mVScrollMode;

View File

@@ -20,9 +20,9 @@ class EE_API UISpinBox : public UIWidget {
virtual void setTheme( UITheme * Theme );
virtual void setPadding( const Recti& padding );
virtual void setPadding( const Rect& padding );
const Recti& getPadding() const;
const Rect& getPadding() const;
virtual void setClickStep( const Float& step );

View File

@@ -75,14 +75,14 @@ class EE_API UITable : public UITouchDragableWidget {
UITable * setSmoothScroll(bool smoothScroll);
Recti getContainerPadding() const;
Rect getContainerPadding() const;
void setContainerPadding( const Recti & containerPadding);
void setContainerPadding( const Rect & containerPadding);
protected:
friend class UIItemContainer<UITable>;
friend class UITableCell;
Recti mContainerPadding;
Rect mContainerPadding;
UIItemContainer<UITable> * mContainer;
UIScrollBar * mVScrollBar;
UIScrollBar * mHScrollBar;

View File

@@ -57,7 +57,7 @@ class EE_API UITextEdit : public UIWidget {
UI_SCROLLBAR_MODE mHScrollBarMode;
UI_SCROLLBAR_MODE mVScrollBarMode;
bool mSkipValueChange;
Recti mContainerPadding;
Rect mContainerPadding;
virtual void onSizeChange();

View File

@@ -76,9 +76,9 @@ class EE_API UITextView : public UIWidget {
UITooltipStyleConfig getFontStyleConfig() const;
const Recti& getPadding() const;
const Rect& getPadding() const;
UITextView * setPadding(const Recti & padding);
UITextView * setPadding(const Rect & padding);
virtual void loadFromXmlNode( const pugi::xml_node& node );
protected:
@@ -89,8 +89,8 @@ class EE_API UITextView : public UIWidget {
Vector2f mRealAlignOffset;
Int32 mSelCurInit;
Int32 mSelCurEnd;
Recti mPadding;
Recti mRealPadding;
Rect mPadding;
Rect mRealPadding;
struct SelPosCache
{
SelPosCache( Vector2f ip, Vector2f ep ) :

View File

@@ -152,7 +152,7 @@ class UIMenuStyleConfig : public UIFontStyleConfig {
UIFontStyleConfig( fontStyleConfig )
{}
Recti Padding = Recti(0, 0, 0, 0);
Rect Padding = Rect(0, 0, 0, 0);
Uint32 MinWidth = 0;
Uint32 MinSpaceForIcons = 0;
Uint32 MinRightMargin = 0;
@@ -188,7 +188,7 @@ class UITooltipStyleConfig : public UIFontStyleConfig {
UIFontStyleConfig( fontStyleConfig )
{}
Recti Padding;
Rect Padding;
};
class UIScaleType {

View File

@@ -51,9 +51,9 @@ class EE_API UITooltip : public UIControlAnim {
virtual void onFontChanged();
virtual void setPadding( const Recti& padding );
virtual void setPadding( const Rect& padding );
const Recti& getPadding() const;
const Rect& getPadding() const;
Text * getTextCache();
@@ -82,7 +82,7 @@ class EE_API UITooltip : public UIControlAnim {
Text * mTextCache;
UITooltipStyleConfig mStyleConfig;
Vector2f mAlignOffset;
Recti mRealPadding;
Rect mRealPadding;
Time mTooltipTime;
UIControl * mTooltipOf;

View File

@@ -48,9 +48,9 @@ class EE_API UIWidget : public UIControlAnim {
void updateAnchorsDistances();
Recti getLayoutMargin() const;
Rect getLayoutMargin() const;
UIWidget * setLayoutMargin(const Recti & margin);
UIWidget * setLayoutMargin(const Rect & margin);
Float getLayoutWeight() const;
@@ -79,14 +79,13 @@ class EE_API UIWidget : public UIControlAnim {
virtual void loadFromXmlNode( const pugi::xml_node& node );
protected:
friend class UIManager;
friend class UILinearLayout;
UITheme * mTheme;
UITooltip * mTooltip;
Sizei mMinControlSize;
Recti mDistToBorder;
Recti mLayoutMargin;
Recti mRealMargin;
Rect mDistToBorder;
Rect mLayoutMargin;
Rect mRealMargin;
Float mLayoutWeight;
Uint32 mLayoutGravity;
LayoutSizeRules mLayoutWidthRules;

View File

@@ -12,7 +12,7 @@ class EE_API View {
View( const int& X, const int& Y, const int& Width, const int& Height );
View( const Recti& View );
View( const Rect& View );
~View();
@@ -35,7 +35,7 @@ class EE_API View {
void setCenter( const Vector2i& center );
/** @return The current view ( Left = X, Right = Width, Top = Y, Bottom = Height ) */
Recti getView() const { return mView; }
Rect getView() const { return mView; }
/** Set a new position to the view */
void setPosition( const int& X, const int& Y );
@@ -49,7 +49,7 @@ class EE_API View {
friend class Window;
bool mNeedUpdate;
Recti mView;
Rect mView;
Vector2f mCenter;
void calcCenter();

View File

@@ -371,7 +371,7 @@ class EE_API Window {
*
* @sa startTextInput()
*/
virtual void setTextInputRect( Recti& rect );
virtual void setTextInputRect( Rect& rect );
/**
* @brief Returns whether the platform has some screen keyboard support.