| 328 | } else { |
| 329 | _mainThreadManager->dispatch(context, [=]() { strongRef->doDestroyContext(context); }); |
| 330 | } |
| 331 | } |
| 332 | |
| 333 | void Runtime::doDestroyContext(const SharedContext& context) { |
| 334 | ScopedMetrics metrics = |
| 335 | Metrics::scopedDestroyContextLatency(getMetrics(), context->getPath().getResourceId().bundleName); |
| 336 | |
| 337 | _contextManager.destroyContext(context); |
| 338 | auto viewNodeTree = _viewNodeManager.getViewNodeTreeForContextId(context->getContextId()); |
| 339 | if (viewNodeTree != nullptr) { |
| 340 | destroyViewNodeTree(*viewNodeTree); |
| 341 | } |
| 342 | } |
no test coverage detected