Clarify ImGui activation in Editor viewport (#1765)
* Clarify ImGui activation in Editor viewport Signed-off-by: John Jones-Steele <jjjoness@amazon.com> * All working following changes from comments in PR Signed-off-by: John Jones-Steele <jjjoness@amazon.com> * One more change Signed-off-by: John Jones-Steele <jjjoness@amazon.com> * fixes from comments in PR. Signed-off-by: John Jones-Steele <jjjoness@amazon.com> * Fixed git merge error Signed-off-by: John Jones-Steele <jjjoness@amazon.com> * Added header to ImGuiBus.h Signed-off-by: John Jones-Steele <jjjoness@amazon.com> * Fix for Jenkins error Signed-off-by: John Jones-Steele <jjjoness@amazon.com> * Minor typo fix Signed-off-by: John Jones-Steele <jjjoness@amazon.com>
This commit is contained in:
@@ -525,6 +525,7 @@ QtViewPaneManager::QtViewPaneManager(QObject* parent)
|
||||
|
||||
// view pane manager is interested when we enter/exit ComponentMode
|
||||
m_componentModeNotifications.BusConnect(AzToolsFramework::GetEntityContextId());
|
||||
m_windowRequest.BusConnect();
|
||||
|
||||
m_componentModeNotifications.SetEnteredComponentModeFunc(
|
||||
[this](const AZStd::vector<AZ::Uuid>& /*componentModeTypes*/)
|
||||
@@ -545,10 +546,23 @@ QtViewPaneManager::QtViewPaneManager(QObject* parent)
|
||||
AzQtComponents::SetWidgetInteractEnabled(widget, on);
|
||||
});
|
||||
});
|
||||
|
||||
m_windowRequest.SetEnableEditorUiFunc(
|
||||
[this](bool enable)
|
||||
{
|
||||
// gray out panels when entering ImGui mode
|
||||
SetDefaultActionsEnabled(
|
||||
enable, m_registeredPanes,
|
||||
[](QWidget* widget, bool on)
|
||||
{
|
||||
AzQtComponents::SetWidgetInteractEnabled(widget, on);
|
||||
});
|
||||
});
|
||||
}
|
||||
|
||||
QtViewPaneManager::~QtViewPaneManager()
|
||||
{
|
||||
m_windowRequest.BusDisconnect();
|
||||
m_componentModeNotifications.BusDisconnect();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user