Open 3D Engine AzFramework API Reference 23.10.0
O3DE is an open-source, fully-featured, high-fidelity, modular 3D engine for building games and simulations, available to every industry.
AzFramework::InputTextNotifications Class Reference

#include <InputTextNotificationBus.h>

Inherits AZ::EBusTraits.

Public Member Functions

virtual ~InputTextNotifications ()=default
 Default destructor.
 
virtual void OnInputTextEvent (const AZStd::string &, bool &)
 
virtual AZ::s32 GetPriority () const
 
bool Compare (const InputTextNotifications *other) const
 

Static Public Attributes

static const AZ::EBusAddressPolicy AddressPolicy = AZ::EBusAddressPolicy::Single
 EBus Trait: input notifications are addressed to a single address.
 
static const AZ::EBusHandlerPolicy HandlerPolicy = AZ::EBusHandlerPolicy::MultipleAndOrdered
 EBus Trait: input notifications can be handled by multiple (ordered) listeners.
 

Detailed Description

EBus interface used to listen for input text events that are broadcast from input devices or channels. Most text input consumers should derive instead from InputTextEventListener (which respects the 'o_hasBeenConsumed' parameter passed to OnInputTextEvent) to ensure text events are processed once. However, if for some reason a system needs to process text regardless of whether it has been consumed by a higher priority listener, they are free to derive directly from InputTextEventNotificationsBus::Handler and simply ignore the 'o_hasBeenConsumed' flag.

Member Function Documentation

◆ Compare()

bool AzFramework::InputTextNotifications::Compare ( const InputTextNotifications other) const
inline

Compare function required by BusHandlerOrderCompare = BusHandlerCompareDefault

Parameters
[in]otherAnother instance of the class to compare
Returns
True if the priority of this handler is greater than the other, false otherwise

◆ GetPriority()

virtual AZ::s32 AzFramework::InputTextNotifications::GetPriority ( ) const
inlinevirtual

Access to the priority of the input notification handler (sorted from highest to lowest)

Returns
Priority of the input notification handler

◆ OnInputTextEvent()

virtual void AzFramework::InputTextNotifications::OnInputTextEvent ( const AZStd::string &  ,
bool &   
)
inlinevirtual

Override to be notified when unicode text input is generated by an input device

Parameters
[in]textUTF8The text emitted by the input device (encoded using UTF-8)
[in,out]o_hasBeenConsumedCheck and/or set whether the text has been handled

The documentation for this class was generated from the following file: