{
if(DALI_LIKELY(Dali::Stage::IsInstalled() && visual))
{
+ // This prevents access to the async text interface until the visual is actually destroyed.
+ TextVisual::SetAsyncTextInterface(visual, nullptr);
Dali::Toolkit::VisualFactory::Get().DiscardVisual(visual);
}
visual.Reset();
{
resourceStatus = Toolkit::Visual::ResourceStatus::READY;
- Actor control = mControl.GetHandle();
- if(!control)
- {
- // Nothing to do.
- ResourceReady(Toolkit::Visual::ResourceStatus::READY);
- return;
- }
-
Text::AsyncTextRenderInfo renderInfo = textInformation.renderInfo;
if(parameters.requestType == Text::Async::COMPUTE_NATURAL_SIZE || parameters.requestType == Text::Async::COMPUTE_HEIGHT_FOR_WIDTH)
}
}
+ Actor control = mControl.GetHandle();
+ if(!control)
+ {
+ // Nothing to do.
+ ResourceReady(Toolkit::Visual::ResourceStatus::READY);
+ return;
+ }
+
// Calculate the size of the visual that can fit the text.
// The size of the text after it has been laid-out, size of pixel data buffer.
Size layoutSize(static_cast<float>(renderInfo.width), static_cast<float>(renderInfo.height));