Activate controllers by scrolling

This commit is contained in:
Patrick Nicolas
2025-11-17 19:53:56 +01:00
parent 9edb8fd2ae
commit 98bb0c56c5
+7
View File
@@ -752,6 +752,13 @@ size_t imgui_context::choose_focused_controller(const std::vector<controller_sta
return index;
}
// scrolling?
for (auto && [index, state]: utils::enumerate(new_states))
{
if (glm::length(state.scroll_value) > constants::gui::scroll_value_thd)
return index;
}
// Else, keep the last controller active
return focused_controller;
}