Minor fixes

This commit is contained in:
Christian Semmler 2023-10-23 10:03:09 -04:00
parent a5c7f01245
commit 4072a73141

View File

@ -11,8 +11,6 @@ void LegoPathPresenter::Init() {}
// OFFSET: LEGO1 0x100448d0 // OFFSET: LEGO1 0x100448d0
LegoPathPresenter::LegoPathPresenter() LegoPathPresenter::LegoPathPresenter()
{ {
const char *internal = this->m_atomId.GetInternal();
internal = NULL;
Init(); Init();
} }
@ -20,9 +18,8 @@ LegoPathPresenter::LegoPathPresenter()
void LegoPathPresenter::RepeatingTickle() void LegoPathPresenter::RepeatingTickle()
{ {
if (this->m_action->GetDuration() == -1) if (this->m_action->GetDuration() == -1)
{
return; return;
}
EndAction(); EndAction();
} }
@ -36,11 +33,12 @@ void LegoPathPresenter::ParseExtra()
MxResult LegoPathPresenter::AddToManager() MxResult LegoPathPresenter::AddToManager()
{ {
MxResult status = FAILURE; MxResult status = FAILURE;
if (VideoManager())
{ if (VideoManager()) {
VideoManager()->AddPresenter(*this); VideoManager()->AddPresenter(*this);
status = SUCCESS; status = SUCCESS;
} }
return status; return status;
} }
@ -48,17 +46,15 @@ MxResult LegoPathPresenter::AddToManager()
void LegoPathPresenter::Destroy(MxBool p_fromDestructor) void LegoPathPresenter::Destroy(MxBool p_fromDestructor)
{ {
if (VideoManager()) if (VideoManager())
{
VideoManager()->RemovePresenter(*this); VideoManager()->RemovePresenter(*this);
}
{ {
MxAutoLocker lock(&this->m_criticalSection); MxAutoLocker lock(&this->m_criticalSection);
Init(); Init();
} }
if (!p_fromDestructor) if (!p_fromDestructor)
{
MxMediaPresenter::Destroy(FALSE); MxMediaPresenter::Destroy(FALSE);
}
} }
// OFFSET: LEGO1 0x10044c10 // OFFSET: LEGO1 0x10044c10