feat(console): add CONSOLELINE destructor

This commit is contained in:
Tristan Cormier 2025-11-20 09:32:31 -05:00 committed by fallenoak
parent 6dc7f8dce3
commit 0ff6dc3112
2 changed files with 13 additions and 0 deletions

View File

@ -40,6 +40,16 @@ static CImVector s_colorArray[] = {
{ 0x00, 0x00, 0x00, 0xC0 }, // BACKGROUND_COLOR { 0x00, 0x00, 0x00, 0xC0 }, // BACKGROUND_COLOR
}; };
CONSOLELINE::~CONSOLELINE() {
if (this->buffer) {
STORM_FREE(this->buffer);
}
if (this->fontPointer) {
GxuFontDestroyString(this->fontPointer);
}
}
void DrawBackground() { void DrawBackground() {
uint16_t indices[] = { uint16_t indices[] = {
0, 1, 2, 3 0, 1, 2, 3

View File

@ -16,6 +16,9 @@ class CONSOLELINE : public TSLinkedNode<CONSOLELINE> {
uint32_t inputstart; uint32_t inputstart;
COLOR_T colorType; COLOR_T colorType;
CGxString* fontPointer; CGxString* fontPointer;
// Member functions
~CONSOLELINE();
}; };
void ConsoleScreenAnimate(float elapsedSec); void ConsoleScreenAnimate(float elapsedSec);