* Refresh cursor reporting on resize.

* Fix invalid size write.

This resolves:
https://github.com/ArthurSonzogni/FTXUI/issues/302
This commit is contained in:
Arthur Sonzogni
2022-01-11 23:06:36 +01:00
committed by GitHub
parent 84299de2e1
commit 1888631bec
3 changed files with 17 additions and 13 deletions

View File

@@ -64,8 +64,9 @@ void ComponentBase::Detach() {
[this](const Component& that) { //
return this == that.get();
});
parent_->children_.erase(it);
ComponentBase* parent = parent_;
parent_ = nullptr;
parent->children_.erase(it); // Might delete |this|.
}
/// @brief Remove all children.