#682 Add created() function for sprites

New function added:
  bool created(void);
to check if sprite has been rotated. Example:

if ( !spr.created() ) Serial.println("Sprite has not been created");
This commit is contained in:
Bodmer
2020-07-07 00:52:55 +01:00
parent 8fc52dc1f5
commit a6d50ea5ef
8 changed files with 18 additions and 6 deletions
+10
View File
@@ -112,6 +112,16 @@ void* TFT_eSprite::createSprite(int16_t w, int16_t h, uint8_t frames)
}
/***************************************************************************************
** Function name: created
** Description: Returns true is sprite has been created
*************************************************************************************x*/
bool TFT_eSprite::created(void)
{
return _created;
}
/***************************************************************************************
** Function name: ~TFT_eSprite
** Description: Class destructor