2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-10 03:07:43 +00:00

CGuiTextSupport: Eliminate the use of const_cast

We can supply a const and non-const variant to eliminate the need to
const_cast here.
This commit is contained in:
Lioncash
2020-03-29 21:33:41 -04:00
parent f3afcf7299
commit 2d8e94911a
2 changed files with 64 additions and 25 deletions

View File

@@ -84,8 +84,10 @@ class CGuiTextSupport {
int x304_pageCounter = 0;
bool x308_multipageFlag = false;
CTextRenderBuffer* GetCurrentPageRenderBuffer() const;
bool _GetIsTextSupportFinishedLoading() const;
CTextRenderBuffer* GetCurrentPageRenderBuffer();
const CTextRenderBuffer* GetCurrentPageRenderBuffer() const;
bool _GetIsTextSupportFinishedLoading();
public:
CGuiTextSupport(CAssetId fontId, const CGuiTextProperties& props, const zeus::CColor& fontCol,
@@ -114,7 +116,7 @@ public:
void SetJustification(EJustification j);
void SetVerticalJustification(EVerticalJustification j);
void SetImageBaseline(bool b);
bool GetIsTextSupportFinishedLoading() const;
bool GetIsTextSupportFinishedLoading();
float GetCurTime() const { return x3c_curTime; }
void SetCurTime(float t) { x3c_curTime = t; }
std::u16string_view GetString() const { return x0_string; }