Remove legacy renderer dependencies in LyShine and move LyShine headers to gem (#6049)
* Remove CryRenderer dependencies Signed-off-by: abrmich <abrmich@amazon.com> * Fix non-unity compile error Signed-off-by: abrmich <abrmich@amazon.com> * Remove ITexture.h reference Signed-off-by: abrmich <abrmich@amazon.com> * Simple file moves from CryCommon to LyShine Gem Signed-off-by: abrmich <abrmich@amazon.com> * More simple file moves from CryCommon to LyShine Gem Signed-off-by: abrmich <abrmich@amazon.com> * Move more headers from CryCommon to LyShine Gem Signed-off-by: abrmich <abrmich@amazon.com> * Add LyShine gem module as a build dependency to fix compile error in some gems Signed-off-by: abrmich <abrmich@amazon.com>
This commit is contained in:
@@ -377,7 +377,7 @@ namespace LyShine
|
||||
}
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
void LyShineSystemComponent::OnCrySystemInitialized([[maybe_unused]] ISystem& system, [[maybe_unused]] const SSystemInitParams& startupParams)
|
||||
void LyShineSystemComponent::OnCrySystemInitialized(ISystem& system, [[maybe_unused]] const SSystemInitParams& startupParams)
|
||||
{
|
||||
#if !defined(AZ_MONOLITHIC_BUILD)
|
||||
// When module is linked dynamically, we must set our gEnv pointer.
|
||||
@@ -387,16 +387,36 @@ namespace LyShine
|
||||
m_pLyShine = new CLyShine(gEnv->pSystem);
|
||||
gEnv->pLyShine = m_pLyShine;
|
||||
|
||||
system.GetILevelSystem()->AddListener(this);
|
||||
|
||||
BroadcastCursorImagePathname();
|
||||
|
||||
if (gEnv->pLyShine)
|
||||
{
|
||||
gEnv->pLyShine->PostInit();
|
||||
}
|
||||
}
|
||||
|
||||
void LyShineSystemComponent::OnCrySystemShutdown([[maybe_unused]] ISystem& system)
|
||||
///////////////////////////////////////////////////////////////////////////////////////////////
|
||||
void LyShineSystemComponent::OnCrySystemShutdown(ISystem& system)
|
||||
{
|
||||
system.GetILevelSystem()->RemoveListener(this);
|
||||
|
||||
gEnv->pLyShine = nullptr;
|
||||
delete m_pLyShine;
|
||||
m_pLyShine = nullptr;
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////
|
||||
void LyShineSystemComponent::OnUnloadComplete([[maybe_unused]] const char* levelName)
|
||||
{
|
||||
// Perform level unload procedures for the LyShine UI system
|
||||
if (gEnv && gEnv->pLyShine)
|
||||
{
|
||||
gEnv->pLyShine->OnLevelUnload();
|
||||
}
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
void LyShineSystemComponent::BroadcastCursorImagePathname()
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user