From c67e537508fb49143a567c3bc3e356aa83190750 Mon Sep 17 00:00:00 2001 From: Christian Semmler Date: Sun, 17 Sep 2023 17:10:38 -0400 Subject: [PATCH] Implement/match MxMediaManager::Tickle (#127) * Implement/match MxMediaManager::Tickle * Remove space --- LEGO1/mxlist.h | 1 + LEGO1/mxmediamanager.cpp | 14 +++++++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/LEGO1/mxlist.h b/LEGO1/mxlist.h index 6f26cad8..da2c3e4e 100644 --- a/LEGO1/mxlist.h +++ b/LEGO1/mxlist.h @@ -83,6 +83,7 @@ class MxListCursor : public MxCore MxBool Find(T *p_obj); void Detach(); MxBool Next(T*& p_obj); + void Reset() { m_match = NULL; } private: MxList *m_list; diff --git a/LEGO1/mxmediamanager.cpp b/LEGO1/mxmediamanager.cpp index d1823c03..b890eec4 100644 --- a/LEGO1/mxmediamanager.cpp +++ b/LEGO1/mxmediamanager.cpp @@ -27,9 +27,21 @@ MxResult MxMediaManager::Init() return SUCCESS; } -// OFFSET: LEGO1 0x100b8790 STUB +// OFFSET: LEGO1 0x100b8790 MxResult MxMediaManager::Tickle() { + MxAutoLocker lock(&this->m_criticalSection); + MxPresenter *presenter; + MxPresenterListCursor cursor(this->m_presenters); + + while (cursor.Next(presenter)) + presenter->Tickle(); + + cursor.Reset(); + + while (cursor.Next(presenter)) + presenter->VTable0x4c(); + return SUCCESS; }