Skip to content

Commit

Permalink
directvt#86 WIP: Fix fullscreen focus
Browse files Browse the repository at this point in the history
  • Loading branch information
o-sdn-o committed Dec 21, 2024
1 parent a56a0f0 commit f74d507
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/vtm.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -1816,7 +1816,7 @@ namespace netxs::app::vtm
if (gear.args_ptr)
{
auto arg = gear.args_ptr->empty() ? -1 : (si32)xml::take_or<bool>(gear.args_ptr->front(), faux);
items.foreach(gear, [&](auto window_ptr)
items.foreach(gear, [&](auto& window_ptr)
{
auto zorder = arg == 0 ? zpos::plain
: arg == 1 ? zpos::topmost
Expand All @@ -1828,7 +1828,7 @@ namespace netxs::app::vtm
}
void close_focused_windows(hids& gear)
{
items.foreach(gear, [&](auto window_ptr)
items.foreach(gear, [&](auto& window_ptr)
{
bell::enqueue(window_ptr, [](auto& boss) // Keep the focus tree intact while processing key events.
{
Expand All @@ -1839,7 +1839,7 @@ namespace netxs::app::vtm
}
void minimize_focused_windows(hids& gear)
{
items.foreach(gear, [&](auto window_ptr)
items.foreach(gear, [&](auto& window_ptr)
{
bell::enqueue(window_ptr, [gear_id = gear.id](auto& boss) // Keep the focus tree intact while processing key events.
{
Expand All @@ -1854,7 +1854,7 @@ namespace netxs::app::vtm
}
void maximize_focused_windows(hids& gear)
{
items.foreach(gear, [&](auto window_ptr)
items.foreach(gear, [&](auto& window_ptr)
{
bell::enqueue(window_ptr, [gear_id = gear.id](auto& boss) // Keep the focus tree intact while processing key events.
{
Expand All @@ -1869,7 +1869,7 @@ namespace netxs::app::vtm
}
void fullscreen_first_focused_window(hids& gear)
{
items.foreach(gear, [&](auto window_ptr)
items.foreach(gear, [&](auto& window_ptr)
{
bell::enqueue(window_ptr, [gear_id = gear.id](auto& boss) // Keep the focus tree intact while processing key events.
{
Expand All @@ -1887,7 +1887,7 @@ namespace netxs::app::vtm
{
auto warp = gear.get_args_or(dent{});
auto focused_window_list = std::vector<sptr>{};
items.foreach(gear, [&](auto window_ptr)
items.foreach(gear, [&](auto& window_ptr)
{
focused_window_list.push_back(window_ptr);
gear.set_handled();
Expand Down

0 comments on commit f74d507

Please sign in to comment.