![]() |
UDocumentation UE5.7 10.02.2026 (Source)
API documentation for Unreal Engine 5.7
|
#include <InputBindingManager.h>
Public Types | |
| enum class | ECommandFilterType { None , DenyList , AllowList } |
Static Public Member Functions | |
| static SLATE_API FInputBindingManager & | Get () |
Public Attributes | |
| FOnRegisterCommandList | OnRegisterCommandList |
| FOnRegisterCommandList | OnUnregisterCommandList |
Manager responsible for creating and processing input bindings.
|
strong |
|
inlinevirtual |
Virtual destructor
| void FInputBindingManager::AddCommandFilter | ( | const FName | InOwnerName, |
| const FName | InBindingContext, | ||
| const FName | InCommandName, | ||
| const ECommandFilterType | FilterType | ||
| ) |
Filters a command by name
| InOwnerName | The name of the owner adding filter so it can be unregistered later |
| InBindingContext | The context in which the command is active |
| InCommandName | The name of the command |
| FilterType | Type of filter to apply |
| bool FInputBindingManager::CommandPassesFilter | ( | const FName | InBindingContext, |
| const FName | InCommandName | ||
| ) | const |
Command passes allow/deny list filters
| InBindingContext | The context in which the command is active |
| InCommandName | The name of the command |
| void FInputBindingManager::CreateInputCommand | ( | const TSharedRef< FBindingContext > & | InBindingContext, |
| TSharedRef< FUICommandInfo > | InUICommandInfo | ||
| ) |
Creates an input command from the specified user interface action
| InBindingContext | The context where the command is valid |
| InUICommandInfo | The user interface action to create the input command from Will automatically bind the user interface action to the command specified by the action so when the command's chord is pressed, the action is executed |
| const TSharedPtr< FUICommandInfo > FInputBindingManager::FindCommandInContext | ( | const FName | InBindingContext, |
| const FInputChord & | InChord, | ||
| bool | bCheckDefault | ||
| ) | const |
Finds the command in the provided context which uses the provided input chord
| InBindingContext | The binding context name |
| InChord | The chord to check against when looking for commands |
| bCheckDefault | Whether or not to check the default chord of commands instead of active chords |
| OutActiveChordIndex | The index into the commands active chord array where the passed in chord was matched. INDEX_NONE if bCheckDefault is true or nothing was found. |
| const TSharedPtr< FUICommandInfo > FInputBindingManager::FindCommandInContext | ( | const FName | InBindingContext, |
| const FName | CommandName | ||
| ) | const |
Finds the command in the provided context which has the provided name
| InBindingContext | The binding context name |
| CommandName | The name of the command to find |
|
static |
| const TSharedPtr< FUICommandInfo > FInputBindingManager::GetCommandInfoFromInputChord | ( | const FName | InBindingContext, |
| const FInputChord & | InChord, | ||
| bool | bCheckDefault | ||
| ) | const |
Returns a command info that is has the same active chord as the provided chord and is in the same binding context or parent context
| InBindingContext | The context in which the command is valid |
| InChord | The chord to match against commands |
| bCheckDefault | Whether or not to check the default chord. Will check the active chord if false |
| void FInputBindingManager::GetCommandInfosFromContext | ( | const FName | InBindingContext, |
| TArray< TSharedPtr< FUICommandInfo > > & | OutCommandInfos | ||
| ) | const |
Returns all known command infos for a given binding context
| InBindingContext | The binding context to get command infos from |
| OutCommandInfos | The list of command infos for the binding context |
| TSharedPtr< FBindingContext > FInputBindingManager::GetContextByName | ( | const FName & | InContextName | ) |
Look up a binding context by name.
| void FInputBindingManager::GetKnownInputContexts | ( | TArray< TSharedPtr< FBindingContext > > & | OutInputContexts | ) | const |
Returns a list of all known input contexts
| OutInputContexts | The generated list of contexts |
| SLATE_API bool FInputBindingManager::GetProjectDefinedChord | ( | const FName | InBindingContext, |
| const FName | InCommandName, | ||
| const EMultipleKeyBindingIndex | InChordIndex, | ||
| FInputChord & | OutUserDefinedChord | ||
| ) |
Gets the project defined chord (if any) from the provided command name
| InBindingContext | The context in which the command is active |
| InCommandName | The name of the command to get the chord from |
| ChordIndex | The index of the key binding (in the multiple key bindings array) |
| bool FInputBindingManager::GetUserDefinedChord | ( | const FName | InBindingContext, |
| const FName | InCommandName, | ||
| const EMultipleKeyBindingIndex | InChordIndex, | ||
| FInputChord & | OutUserDefinedChord | ||
| ) |
Gets the user defined chord (if any) from the provided command name
| InBindingContext | The context in which the command is active |
| InCommandName | The name of the command to get the chord from |
| ChordIndex | The index of the key binding (in the multiple key bindings array) |
Gets the user defined chord (if any) from the provided command name
| InBindingContext | The context in which the command is active |
| InCommandName | The name of the command to get the chord from |
|
virtual |
Called when the active chord is changed on a command
| CommandInfo | The command that had the active chord changed. |
| bool FInputBindingManager::RegisterCommandList | ( | const ::FName | InBindingContext, |
| TSharedRef< FUICommandList > | CommandList | ||
| ) | const |
Exposes the given command list and its context to all OnRegisterCommandList subscribers
| InBindingContext | The context in which the command list is active |
| CommandList | The command list to expose to subscribers |
| TSharedPtr< FUICommandList > FInputBindingManager::RegisterNewCommandList | ( | const FName | InBindingContext | ) | const |
Exposes a new given command list from the given context to all OnRegisterCommandList subscribers
| InBindingContext | The context in which the command list is active |
|
inline |
Registers a delegate to be called when a user-defined chord is edited
Remove the context with this name
| void FInputBindingManager::RemoveInputCommand | ( | const TSharedRef< FBindingContext > & | InBindingContext, |
| TSharedRef< FUICommandInfo > | InUICommandInfo | ||
| ) |
Removes an input command, allowing a new one to take its place
| InBindingContext | The context where the command is valid |
| InUICommandInfo | The user interface action to remove |
| void FInputBindingManager::RemoveUserDefinedChords | ( | ) |
Removes any user defined chords
| void FInputBindingManager::SaveInputBindings | ( | ) |
Saves the user defined chords to a json file
Removes all filters associated with an owner
| bool FInputBindingManager::UnregisterCommandList | ( | const ::FName | InBindingContext, |
| TSharedRef< FUICommandList > | CommandList | ||
| ) | const |
Exposes the given command list and its context to all OnUnregisterCommandList subscribers
| InBindingContext | The context in which the command list is active |
| CommandList | The command list to expose to subscribers |
|
inline |
Unregisters a delegate to be called when a user-defined chord is edited
| FOnRegisterCommandList FInputBindingManager::OnRegisterCommandList |
A delegate for systems to subscribe to any other system exposing their command lists
| FOnRegisterCommandList FInputBindingManager::OnUnregisterCommandList |
A delegate for systems to subscribe to any other system unregistering their command lists