mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-04-28 15:55:39 +00:00
review notes from Az
Should render fallback for namedTarget if namedTarget fails Add safety around namedtarget getTexture to stop assert Missing assets should revert to fallback image and print a warning to console Remove REFACTOR tag from all macros.
This commit is contained in:
parent
b707b2e2b7
commit
73ad92b757
60 changed files with 189 additions and 164 deletions
|
|
@ -70,7 +70,7 @@ void GuiBitmapCtrl::initPersistFields()
|
|||
docsURL;
|
||||
addGroup("Bitmap");
|
||||
|
||||
INITPERSISTFIELD_IMAGEASSET_REFACTOR(Bitmap, GuiBitmapCtrl, "The bitmap to render in this BitmapCtrl.")
|
||||
INITPERSISTFIELD_IMAGEASSET(Bitmap, GuiBitmapCtrl, "The bitmap to render in this BitmapCtrl.")
|
||||
|
||||
addField("color", TypeColorI, Offset(mColor, GuiBitmapCtrl), "color mul");
|
||||
addField("wrap", TypeBool, Offset(mWrap, GuiBitmapCtrl), "If true, the bitmap is tiled inside the control rather than stretched to fit.");
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ protected:
|
|||
|
||||
/// Name of the bitmap file. If this is 'texhandle' the bitmap is not loaded
|
||||
/// from a file but rather set explicitly on the control.
|
||||
DECLARE_IMAGEASSET_REFACTOR(GuiBitmapCtrl, Bitmap, GFXDefaultGUIProfile)
|
||||
DECLARE_IMAGEASSET(GuiBitmapCtrl, Bitmap, GFXDefaultGUIProfile)
|
||||
|
||||
Point2I mStartPoint;
|
||||
ColorI mColor;
|
||||
|
|
|
|||
|
|
@ -826,9 +826,9 @@ IMPLEMENT_CALLBACK(GuiGameSettingsCtrl, onAxisEvent, void, (const char* device,
|
|||
void GuiGameSettingsCtrl::initPersistFields()
|
||||
{
|
||||
docsURL;
|
||||
INITPERSISTFIELD_IMAGEASSET_REFACTOR(KeybindBitmap, GuiGameSettingsCtrl, "Bitmap used to display the bound key for this keybind option.");
|
||||
INITPERSISTFIELD_IMAGEASSET_REFACTOR(PreviousBitmap, GuiGameSettingsCtrl, "Bitmap used for the previous button when in list mode.");
|
||||
INITPERSISTFIELD_IMAGEASSET_REFACTOR(NextBitmap, GuiGameSettingsCtrl, "Bitmap used for the next button when in list mode.");
|
||||
INITPERSISTFIELD_IMAGEASSET(KeybindBitmap, GuiGameSettingsCtrl, "Bitmap used to display the bound key for this keybind option.");
|
||||
INITPERSISTFIELD_IMAGEASSET(PreviousBitmap, GuiGameSettingsCtrl, "Bitmap used for the previous button when in list mode.");
|
||||
INITPERSISTFIELD_IMAGEASSET(NextBitmap, GuiGameSettingsCtrl, "Bitmap used for the next button when in list mode.");
|
||||
|
||||
addFieldV("arrowSize", TypeRangedS32, Offset(mArrowSize, GuiGameSettingsCtrl), &CommonValidators::PositiveInt,
|
||||
"Size of the arrow buttons' extents");
|
||||
|
|
|
|||
|
|
@ -72,9 +72,9 @@ protected:
|
|||
Point2F mRange; ///< When working as a slider, this sets our min/max range
|
||||
|
||||
//Keybind option
|
||||
DECLARE_IMAGEASSET_REFACTOR(GuiGameSettingsCtrl, KeybindBitmap, GFXDefaultGUIProfile)
|
||||
DECLARE_IMAGEASSET_REFACTOR(GuiGameSettingsCtrl, PreviousBitmap, GFXDefaultGUIProfile)
|
||||
DECLARE_IMAGEASSET_REFACTOR(GuiGameSettingsCtrl, NextBitmap, GFXDefaultGUIProfile)
|
||||
DECLARE_IMAGEASSET(GuiGameSettingsCtrl, KeybindBitmap, GFXDefaultGUIProfile)
|
||||
DECLARE_IMAGEASSET(GuiGameSettingsCtrl, PreviousBitmap, GFXDefaultGUIProfile)
|
||||
DECLARE_IMAGEASSET(GuiGameSettingsCtrl, NextBitmap, GFXDefaultGUIProfile)
|
||||
|
||||
S32 mArrowSize;
|
||||
S32 mColumnSplit; //Padding between the leftmost edge of the control, and the left side of the 'option'.
|
||||
|
|
|
|||
|
|
@ -126,7 +126,7 @@ protected:
|
|||
NumBitmapModes = 2
|
||||
};
|
||||
|
||||
DECLARE_IMAGEASSET_ARRAY_REFACTOR(GuiPopUpMenuCtrl, Bitmap, GFXDefaultGUIProfile, NumBitmapModes)
|
||||
DECLARE_IMAGEASSET_ARRAY(GuiPopUpMenuCtrl, Bitmap, GFXDefaultGUIProfile, NumBitmapModes)
|
||||
|
||||
Point2I mBitmapBounds; // Added
|
||||
S32 mIdMax;
|
||||
|
|
|
|||
|
|
@ -131,7 +131,7 @@ class GuiPopUpMenuCtrlEx : public GuiTextCtrl
|
|||
NumBitmapModes = 2
|
||||
};
|
||||
|
||||
DECLARE_IMAGEASSET_ARRAY_REFACTOR(GuiPopUpMenuCtrlEx, Bitmap, GFXDefaultGUIProfile, NumBitmapModes)
|
||||
DECLARE_IMAGEASSET_ARRAY(GuiPopUpMenuCtrlEx, Bitmap, GFXDefaultGUIProfile, NumBitmapModes)
|
||||
|
||||
Point2I mBitmapBounds; // Added
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue