They've nailed it down to the following logic FUIActionBinding::TryCreate which doesn't check for the InputAction specified.
// Make sure there is no existing binding for the same action associated with the same widget for (const TPair<FUIActionBindingHandle, TSharedPtr<FUIActionBinding>>& HandleBindingPair : AllRegistrationsByHandle) { if (HandleBindingPair.Value->ActionName == BindArgs.GetActionName() && HandleBindingPair.Value->InputEvent == BindArgs.KeyEvent && HandleBindingPair.Value->BoundWidget.Get() == &InBoundWidget) { UE_LOG(LogUIActionRouter, Error, TEXT("Widget [%s] is already bound to action [%s] [%s]! A given widget can only bind the same action once. Unregister existing binding first if you wish to change any aspect of the binding"), *InBoundWidget.GetName(), *HandleBindingPair.Value->ActionName.ToString(), InputEventToString(BindArgs.KeyEvent)); return FUIActionBindingHandle(); } }
UDN user was attempting to use Enhanced Input for Common UI but ran into an issue when registering a second UI binding.
In NativeConstruct they're binding an additional action. This widget is a UCommonActivableWidget derivative with bIsBackHandler enabled (with an enhanced input action backing it).
if (IsValid(CloseAction)) { FBindUIActionArgs BindArgs(CloseAction, FSimpleDelegate::CreateUObject(this, &ThisClass::DeactivateWidget)); BindArgs.bDisplayInActionBar = true; CloseActionHandle = RegisterUIActionBinding(BindArgs); }
Doing this will produce an error message in the log stating something like the following:
`LogUIActionRouter: Error: Widget [wbp_debug_menu_C_0] is already bound to action [None] [Pressed]! A given widget can only bind the same action once. Unregister existing binding first if you wish to change any aspect of the binding`
There's no existing public thread on this issue, so head over to Questions & Answers just mention UE-193679 in the post.
1 |
Component | UE - Editor - UI Systems - UMG |
---|---|
Affects Versions | 5.2 |
Target Fix | 5.6 |
Fix Commit | 25214952 |
---|
Created | Aug 23, 2023 |
---|---|
Resolved | Oct 11, 2024 |
Updated | Oct 11, 2024 |