code duplication prune. should aid in stability

This commit is contained in:
AzaezelX 2021-10-03 02:56:26 -05:00
parent 10f2453cee
commit 98a079a797
123 changed files with 632 additions and 966 deletions

View file

@ -129,7 +129,7 @@ GuiBitmapButtonCtrl::GuiBitmapButtonCtrl()
setExtent( 140, 30 );
mMasked = false;
INIT_IMAGEASSET(Bitmap);
INIT_ASSET(Bitmap);
}
//-----------------------------------------------------------------------------
@ -668,4 +668,4 @@ bool GuiBitmapButtonCtrl::pointInControl(const Point2I& parentCoordPoint)
return Parent::pointInControl(parentCoordPoint);
}
DEF_IMAGEASSET_BINDS(GuiBitmapButtonCtrl, Bitmap);
DEF_ASSET_BINDS(GuiBitmapButtonCtrl, Bitmap);

View file

@ -119,7 +119,7 @@ class GuiBitmapButtonCtrl : public GuiButtonCtrl
BitmapMode mBitmapMode;
DECLARE_IMAGEASSET(GuiBitmapButtonCtrl, Bitmap, onBitmapChange, GFXDefaultGUIProfile);
DECLARE_IMAGEASSET_SETGET(GuiBitmapButtonCtrl, Bitmap);
DECLARE_ASSET_SETGET(GuiBitmapButtonCtrl, Bitmap);
/// alpha masking
bool mMasked;

View file

@ -85,7 +85,7 @@ ConsoleDocClass( GuiIconButtonCtrl,
GuiIconButtonCtrl::GuiIconButtonCtrl()
{
INIT_IMAGEASSET(Bitmap);
INIT_ASSET(Bitmap);
mTextLocation = TextLocLeft;
mIconLocation = IconLocLeft;
mTextMargin = 4;
@ -412,4 +412,4 @@ void GuiIconButtonCtrl::renderBitmapArray(RectI &bounds, S32 state)
}
}
DEF_IMAGEASSET_BINDS(GuiIconButtonCtrl, Bitmap);
DEF_ASSET_BINDS(GuiIconButtonCtrl, Bitmap);

View file

@ -43,7 +43,7 @@ private:
protected:
DECLARE_IMAGEASSET(GuiIconButtonCtrl, Bitmap, onImageChanged, GFXTexturePersistentSRGBProfile);
DECLARE_IMAGEASSET_SETGET(GuiIconButtonCtrl, Bitmap);
DECLARE_ASSET_SETGET(GuiIconButtonCtrl, Bitmap);
S32 mIconLocation;
S32 mTextLocation;

View file

@ -43,9 +43,9 @@ ConsoleDocClass( GuiToolboxButtonCtrl,
//-------------------------------------
GuiToolboxButtonCtrl::GuiToolboxButtonCtrl()
{
INIT_IMAGEASSET(NormalBitmap);
INIT_IMAGEASSET(LoweredBitmap);
INIT_IMAGEASSET(HoverBitmap);
INIT_ASSET(NormalBitmap);
INIT_ASSET(LoweredBitmap);
INIT_ASSET(HoverBitmap);
setMinExtent(Point2I(16,16));
setExtent(48, 48);
@ -193,6 +193,6 @@ void GuiToolboxButtonCtrl::renderButton(GFXTexHandle &texture, Point2I &offset,
}
}
DEF_IMAGEASSET_BINDS(GuiToolboxButtonCtrl, NormalBitmap);
DEF_IMAGEASSET_BINDS(GuiToolboxButtonCtrl, LoweredBitmap);
DEF_IMAGEASSET_BINDS(GuiToolboxButtonCtrl, HoverBitmap);
DEF_ASSET_BINDS(GuiToolboxButtonCtrl, NormalBitmap);
DEF_ASSET_BINDS(GuiToolboxButtonCtrl, LoweredBitmap);
DEF_ASSET_BINDS(GuiToolboxButtonCtrl, HoverBitmap);

View file

@ -40,11 +40,11 @@ private:
protected:
DECLARE_IMAGEASSET(GuiToolboxButtonCtrl, NormalBitmap, onNormalImageChanged, GFXTexturePersistentSRGBProfile);
DECLARE_IMAGEASSET_SETGET(GuiToolboxButtonCtrl, NormalBitmap);
DECLARE_ASSET_SETGET(GuiToolboxButtonCtrl, NormalBitmap);
DECLARE_IMAGEASSET(GuiToolboxButtonCtrl, LoweredBitmap, onLoweredImageChanged, GFXTexturePersistentSRGBProfile);
DECLARE_IMAGEASSET_SETGET(GuiToolboxButtonCtrl, LoweredBitmap);
DECLARE_ASSET_SETGET(GuiToolboxButtonCtrl, LoweredBitmap);
DECLARE_IMAGEASSET(GuiToolboxButtonCtrl, HoverBitmap, onHoverImageChanged, GFXTexturePersistentSRGBProfile);
DECLARE_IMAGEASSET_SETGET(GuiToolboxButtonCtrl, HoverBitmap);
DECLARE_ASSET_SETGET(GuiToolboxButtonCtrl, HoverBitmap);
void renderButton(GFXTexHandle &texture, Point2I &offset, const RectI& updateRect);
void renderStateRect( GFXTexHandle &texture, const RectI& rect );