Moved toggle pivot to lower in the context menu, converted all context menu additions to use a singular mechanism (#1209)
This commit is contained in:
@@ -61,6 +61,7 @@ namespace Camera
|
||||
|
||||
void CameraEditorSystemComponent::Activate()
|
||||
{
|
||||
AzToolsFramework::EditorContextMenuBus::Handler::BusConnect();
|
||||
AzToolsFramework::EditorEvents::Bus::Handler::BusConnect();
|
||||
Camera::EditorCameraSystemRequestBus::Handler::BusConnect();
|
||||
Camera::CameraViewRegistrationRequestsBus::Handler::BusConnect();
|
||||
@@ -71,6 +72,7 @@ namespace Camera
|
||||
Camera::CameraViewRegistrationRequestsBus::Handler::BusDisconnect();
|
||||
Camera::EditorCameraSystemRequestBus::Handler::BusDisconnect();
|
||||
AzToolsFramework::EditorEvents::Bus::Handler::BusDisconnect();
|
||||
AzToolsFramework::EditorContextMenuBus::Handler::BusDisconnect();
|
||||
}
|
||||
|
||||
void CameraEditorSystemComponent::PopulateEditorGlobalContextMenu(QMenu* menu, const AZ::Vector2&, int flags)
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
|
||||
#include <AzToolsFramework/API/ToolsApplicationAPI.h>
|
||||
#include <AzToolsFramework/API/EditorCameraBus.h>
|
||||
#include <AzToolsFramework/Editor/EditorContextMenuBus.h>
|
||||
|
||||
#include "CameraViewRegistrationBus.h"
|
||||
|
||||
@@ -25,6 +26,7 @@ namespace Camera
|
||||
, private AzToolsFramework::EditorEvents::Bus::Handler
|
||||
, private EditorCameraSystemRequestBus::Handler
|
||||
, private CameraViewRegistrationRequestsBus::Handler
|
||||
, private AzToolsFramework::EditorContextMenuBus::Handler
|
||||
{
|
||||
public:
|
||||
AZ_COMPONENT(CameraEditorSystemComponent, "{769802EB-722A-4F89-A475-DA396DA1FDCC}");
|
||||
@@ -40,9 +42,13 @@ namespace Camera
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
private:
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
// AzToolsFramework::EditorContextMenuBus
|
||||
void PopulateEditorGlobalContextMenu(QMenu* menu, const AZ::Vector2& point, int flags) override;
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
// AzToolsFramework::EditorEvents
|
||||
void PopulateEditorGlobalContextMenu(QMenu *menu, const AZ::Vector2& point, int flags) override;
|
||||
void NotifyRegisterViews() override;
|
||||
//////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
@@ -134,6 +134,7 @@ namespace PhysX
|
||||
void EditorSystemComponent::Activate()
|
||||
{
|
||||
Physics::EditorWorldBus::Handler::BusConnect();
|
||||
AzToolsFramework::EditorContextMenuBus::Handler::BusConnect();
|
||||
|
||||
m_onMaterialLibraryLoadErrorEventHandler = AzPhysics::SystemEvents::OnMaterialLibraryLoadErrorEvent::Handler(
|
||||
[this]([[maybe_unused]] AzPhysics::SystemEvents::MaterialLibraryLoadErrorType error)
|
||||
@@ -168,6 +169,7 @@ namespace PhysX
|
||||
{
|
||||
AzToolsFramework::EditorEntityContextNotificationBus::Handler::BusDisconnect();
|
||||
AzToolsFramework::EditorEvents::Bus::Handler::BusDisconnect();
|
||||
AzToolsFramework::EditorContextMenuBus::Handler::BusDisconnect();
|
||||
Physics::EditorWorldBus::Handler::BusDisconnect();
|
||||
|
||||
if (auto* physicsSystem = AZ::Interface<AzPhysics::SystemInterface>::Get())
|
||||
|
||||
@@ -15,6 +15,7 @@
|
||||
#include <AzCore/Component/Component.h>
|
||||
#include <AzFramework/Physics/SystemBus.h>
|
||||
#include <AzFramework/Physics/Common/PhysicsEvents.h>
|
||||
#include <AzToolsFramework/Editor/EditorContextMenuBus.h>
|
||||
#include <AzToolsFramework/Entity/EditorEntityContextBus.h>
|
||||
|
||||
namespace AzPhysics
|
||||
@@ -32,6 +33,7 @@ namespace PhysX
|
||||
, public Physics::EditorWorldBus::Handler
|
||||
, private AzToolsFramework::EditorEntityContextNotificationBus::Handler
|
||||
, private AzToolsFramework::EditorEvents::Bus::Handler
|
||||
, private AzToolsFramework::EditorContextMenuBus::Handler
|
||||
{
|
||||
public:
|
||||
AZ_COMPONENT(EditorSystemComponent, "{560F08DC-94F5-4D29-9AD4-CDFB3B57C654}");
|
||||
@@ -62,8 +64,10 @@ namespace PhysX
|
||||
void OnStartPlayInEditorBegin() override;
|
||||
void OnStopPlayInEditor() override;
|
||||
|
||||
// AztoolsFramework::EditorEvents::Bus::Handler
|
||||
// AztoolsFramework::EditorContextMenuBus::Handler
|
||||
void PopulateEditorGlobalContextMenu(QMenu* menu, const AZ::Vector2& point, int flags) override;
|
||||
|
||||
// AztoolsFramework::EditorEvents::Bus::Handler
|
||||
void NotifyRegisterViews() override;
|
||||
|
||||
AZStd::optional<AZ::Data::Asset<AZ::Data::AssetData>> RetrieveDefaultMaterialLibrary();
|
||||
|
||||
@@ -66,6 +66,7 @@ namespace ScriptCanvasEditor
|
||||
SystemComponent::~SystemComponent()
|
||||
{
|
||||
AzToolsFramework::UnregisterViewPane(LyViewPane::ScriptCanvas);
|
||||
AzToolsFramework::EditorContextMenuBus::Handler::BusDisconnect();
|
||||
AzToolsFramework::EditorEvents::Bus::Handler::BusDisconnect();
|
||||
AzFramework::AssetCatalogEventBus::Handler::BusDisconnect();
|
||||
AzToolsFramework::AssetSeedManagerRequests::Bus::Handler::BusDisconnect();
|
||||
@@ -119,6 +120,7 @@ namespace ScriptCanvasEditor
|
||||
void SystemComponent::Init()
|
||||
{
|
||||
AzToolsFramework::EditorEvents::Bus::Handler::BusConnect();
|
||||
AzToolsFramework::EditorContextMenuBus::Handler::BusConnect();
|
||||
}
|
||||
|
||||
void SystemComponent::Activate()
|
||||
|
||||
@@ -22,6 +22,7 @@
|
||||
|
||||
#include <AzToolsFramework/API/ToolsApplicationAPI.h>
|
||||
#include <AzToolsFramework/AssetBrowser/AssetBrowserBus.h>
|
||||
#include <AzToolsFramework/Editor/EditorContextMenuBus.h>
|
||||
#include <Editor/Assets/ScriptCanvasAssetTracker.h>
|
||||
|
||||
#include <AzToolsFramework/Asset/AssetSeedManager.h>
|
||||
@@ -42,6 +43,7 @@ namespace ScriptCanvasEditor
|
||||
, private AZ::Data::AssetBus::MultiHandler
|
||||
, private AZ::Interface<IUpgradeRequests>::Registrar
|
||||
, private AzToolsFramework::AssetSeedManagerRequests::Bus::Handler
|
||||
, private AzToolsFramework::EditorContextMenuBus::Handler
|
||||
{
|
||||
public:
|
||||
AZ_COMPONENT(SystemComponent, "{1DE7A120-4371-4009-82B5-8140CB1D7B31}");
|
||||
@@ -71,8 +73,12 @@ namespace ScriptCanvasEditor
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// AztoolsFramework::EditorEvents::Bus::Handler...
|
||||
// AztoolsFramework::EditorContextMenuBus::Handler...
|
||||
void PopulateEditorGlobalContextMenu(QMenu* menu, const AZ::Vector2& point, int flags) override;
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
// AztoolsFramework::EditorEvents::Bus::Handler...
|
||||
void NotifyRegisterViews() override;
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
|
||||
|
||||
Reference in New Issue
Block a user