Fix spawned selector lifetime
This commit is contained in:
parent
8425900fe0
commit
c0c659ee61
1 changed files with 1 additions and 0 deletions
|
|
@ -305,6 +305,7 @@ namespace psemek::ui
|
|||
|
||||
auto patch_callback_recursive = util::recursive([&](auto && self, struct selector * target) -> void {
|
||||
target->on_selected([target, close, cb = target->on_selected()](std::size_t index){
|
||||
[[maybe_unused]] auto shared_target = target->shared_from_this();
|
||||
close();
|
||||
if (cb)
|
||||
cb(index);
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue