Merge remote-tracking branch 'upstream/development' into hultonha_LYN-2349_tube_delete_crash
Signed-off-by: hultonha <hultonha@amazon.co.uk>
This commit is contained in:
@@ -116,7 +116,7 @@ namespace AZ
|
||||
{
|
||||
const char* uuidString = nullptr;
|
||||
unsigned int uuidStringLength = 0;
|
||||
if (dc.ReadArg(0, uuidString) && dc.ReadValue(1, uuidStringLength))
|
||||
if (dc.ReadArg(0, uuidString) && dc.ReadArg(1, uuidStringLength))
|
||||
{
|
||||
dc.PushResult(Uuid(uuidString, uuidStringLength));
|
||||
}
|
||||
|
||||
+25
-5
@@ -205,6 +205,25 @@ namespace AzFramework
|
||||
class InputDeviceImplementationRequest : public AZ::EBusTraits
|
||||
{
|
||||
public:
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//! EBus Trait: requests can be addressed to a specific InputDeviceId so that they are only
|
||||
//! handled by one input device that has connected to the bus using that unique id, or they
|
||||
//! can be broadcast to all input devices that have connected to the bus, regardless of id.
|
||||
//! Connected input devices are ordered by their local player index from lowest to highest.
|
||||
static const AZ::EBusAddressPolicy AddressPolicy = AZ::EBusAddressPolicy::ByIdAndOrdered;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//! EBus Trait: requests should be handled by only one input device connected to each id
|
||||
static const AZ::EBusHandlerPolicy HandlerPolicy = AZ::EBusHandlerPolicy::Single;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//! EBus Trait: requests can be addressed to a specific InputDeviceId
|
||||
using BusIdType = InputDeviceId;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//! EBus Trait: requests are handled by connected devices in the order of local player index
|
||||
using BusIdOrderCompare = AZStd::less<BusIdType>;
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//! Alias for the EBus implementation of this interface
|
||||
using Bus = AZ::EBus<InputDeviceImplementationRequest<InputDeviceType>>;
|
||||
@@ -214,11 +233,12 @@ namespace AzFramework
|
||||
using CreateFunctionType = typename InputDeviceType::Implementation*(*)(InputDeviceType&);
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//! Create a custom implementation for all the existing instances of this input device type.
|
||||
//! Set a custom implementation for this input device type, either for a specific instance
|
||||
//! by addressing the call to an InputDeviceId, or for all existing instances by broadcast.
|
||||
//! Passing InputDeviceType::Implementation::Create as the argument will create the default
|
||||
//! device implementation, while passing nullptr will delete any existing implementation.
|
||||
//! \param[in] createFunction Pointer to the function that will create the implementation.
|
||||
virtual void CreateCustomImplementation(CreateFunctionType createFunction) = 0;
|
||||
virtual void SetCustomImplementation(CreateFunctionType createFunction) = 0;
|
||||
};
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
@@ -238,7 +258,7 @@ namespace AzFramework
|
||||
AZ_INLINE InputDeviceImplementationRequestHandler(InputDeviceType& inputDevice)
|
||||
: m_inputDevice(inputDevice)
|
||||
{
|
||||
InputDeviceImplementationRequest<InputDeviceType>::Bus::Handler::BusConnect();
|
||||
InputDeviceImplementationRequest<InputDeviceType>::Bus::Handler::BusConnect(m_inputDevice.GetInputDeviceId());
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
@@ -251,8 +271,8 @@ namespace AzFramework
|
||||
using CreateFunctionType = typename InputDeviceType::Implementation*(*)(InputDeviceType&);
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////
|
||||
//! \ref InputDeviceImplementationRequest<InputDeviceType>::CreateCustomImplementation
|
||||
AZ_INLINE void CreateCustomImplementation(CreateFunctionType createFunction) override
|
||||
//! \ref InputDeviceImplementationRequest<InputDeviceType>::SetCustomImplementation
|
||||
AZ_INLINE void SetCustomImplementation(CreateFunctionType createFunction) override
|
||||
{
|
||||
AZStd::unique_ptr<typename InputDeviceType::Implementation> newImplementation;
|
||||
if (createFunction)
|
||||
|
||||
@@ -63,6 +63,9 @@ namespace AzToolsFramework
|
||||
//! Signal the Python handler to stop
|
||||
virtual bool StopPython(bool silenceWarnings = false) = 0;
|
||||
|
||||
//! Query to determine if the Python VM has been initialized indicating an active state
|
||||
virtual bool IsPythonActive() = 0;
|
||||
|
||||
//! Determines if the caller needs to wait for the Python VM to initialize (non-main thread only)
|
||||
virtual void WaitForInitialization() {}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user