Merge pull request #721 from OTHGMars/guiBmpFix

GuiBitmapCtrl named texture fixes.
This commit is contained in:
Brian Roberts 2022-01-22 01:03:05 -06:00 committed by GitHub
commit 3b12fefdf1
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -98,7 +98,8 @@ bool GuiBitmapCtrl::onWake()
return false; return false;
setActive(true); setActive(true);
setBitmap(getBitmap()); if (mBitmapName != StringTable->insert("texhandle"))
setBitmap(getBitmap());
return true; return true;
} }
@ -152,7 +153,7 @@ void GuiBitmapCtrl::setBitmapHandle(GFXTexHandle handle, bool resize)
{ {
mBitmap = handle; mBitmap = handle;
mBitmapName = String("texhandle"); mBitmapName = StringTable->insert("texhandle");
// Resize the control to fit the bitmap // Resize the control to fit the bitmap
if (resize) if (resize)