Add weak pointer handling (#3763)

This commit is contained in:
Tim Sylvester
2025-09-02 07:35:25 -07:00
committed by GitHub
parent 5ba738f30c
commit 764f73c97a
28 changed files with 82 additions and 38 deletions

View File

@@ -129,7 +129,9 @@ const LayerTypeInfo* <%- camelize(type) %>Layer::Impl::staticTypeInfo() noexcept
: Layer(std::move(impl_)) {
}
<%- camelize(type) %>Layer::~<%- camelize(type) %>Layer() = default;
<%- camelize(type) %>Layer::~<%- camelize(type) %>Layer() {
weakFactory.invalidateWeakPtrs();
}
const <%- camelize(type) %>Layer::Impl& <%- camelize(type) %>Layer::impl() const {
return static_cast<const Impl&>(*baseImpl);