Hey Cody,
Thanks for your answer!
So I was a bit afraid of the codebase you mentionned. So I started with your proposed UCommonButtonBase inheritance idea. It works but requires a bit of effort: in order to work, I have to add a, input action binding from a datatable for all my modules. The problem is that when A is pressed, they all rect to it. So I have to filter and check that a module if the focused one before I start to respond to the On Clicked event. It is doable though, maybe I can try to install/uninstall the input action when the widgets get focus / unfocused, to have a simpler C++ solution, and avoid the branch in every blueprint graph.
Before I applied this to every widget of my hierarchy, I still tried to debug FCommonAnalogCursor::HandleKeyDownEvent, adding a selective breakpoint to pressing EKeys::Gamepad_FaceButton_Bottom. Going step by step, I found out that FActionRouterBindingCollection::ProcessHoldInput is setting the result to handled, by finding A+Hold binding in the ActionBindings container. See attached image.
I am not sure what is best to do from here. Should I modify the code and add a test to check if the Key is Gamepad_FaceButton_Bottom and not consider it handled?
`Binding->BeginHold();
if (Key != EKeys::Gamepad_FaceButton_Bottom)
{
ProcessResult = EProcessHoldActionResult::Handled;
}
Binding->OnHoldActionPressed.Broadcast();`
Or is the UCommonButtonBase scheme better?
Thanks!
Mathieu