mirror of
https://github.com/RetroDECK/ES-DE.git
synced 2024-11-25 23:55:38 +00:00
Quick fix for the stack overflow with DateTimeComponents in a ComponentGrid.
This commit is contained in:
parent
90bd22df14
commit
da86b618c4
|
@ -256,6 +256,8 @@ void DateTimeComponent::updateTextCache()
|
||||||
if(mAutoSize)
|
if(mAutoSize)
|
||||||
{
|
{
|
||||||
mSize = mTextCache->metrics.size;
|
mSize = mTextCache->metrics.size;
|
||||||
|
|
||||||
|
mAutoSize = false;
|
||||||
if(getParent())
|
if(getParent())
|
||||||
getParent()->onSizeChanged();
|
getParent()->onSizeChanged();
|
||||||
}
|
}
|
||||||
|
@ -302,6 +304,7 @@ void DateTimeComponent::setFont(std::shared_ptr<Font> font)
|
||||||
|
|
||||||
void DateTimeComponent::onSizeChanged()
|
void DateTimeComponent::onSizeChanged()
|
||||||
{
|
{
|
||||||
|
mAutoSize = false;
|
||||||
updateTextCache();
|
updateTextCache();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue