Skip to content

Commit

Permalink
directvt#400 WIP: Try to sync UI thread
Browse files Browse the repository at this point in the history
  • Loading branch information
o-sdn-o committed Sep 13, 2023
1 parent 219bff5 commit 2a63f39
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 2 deletions.
8 changes: 8 additions & 0 deletions src/netxs/apps.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,14 @@ namespace netxs::app::shared
->invoke([&](auto& boss)
{
//todo unify: Same as in app::term (term.hpp).
boss.LISTEN(tier::anycast, e2::form::proceed::quit::any, fast)
{
boss.SIGNAL(tier::preview, e2::form::proceed::quit::one, fast);
};
boss.LISTEN(tier::preview, e2::form::proceed::quit::one, fast)
{
boss.sighup(fast);
};
boss.LISTEN(tier::anycast, app::term::events::cmd, cmd)
{
boss.exec_cmd(static_cast<ui::term::commands::ui::commands>(cmd));
Expand Down
4 changes: 2 additions & 2 deletions src/netxs/apps/tile.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -675,9 +675,9 @@ namespace netxs::app::tile
};
boss.LISTEN(tier::preview, e2::form::proceed::quit::one, fast)
{
if (boss.count() > 1 && boss.back()->base::kind() == 0)
if (boss.count() > 0 && boss.back()->base::root()) // Walking a nested visual tree.
{
boss.back()->SIGNAL(tier::anycast, e2::form::proceed::quit::one, fast);
boss.back()->SIGNAL(tier::anycast, e2::form::proceed::quit::one, fast); // Forward a quit message to hosted app in order to schedule a cleanup.
}
else boss.SIGNAL(tier::release, e2::form::proceed::quit::one, fast);
};
Expand Down

0 comments on commit 2a63f39

Please sign in to comment.