StartAction match

This commit is contained in:
Christian Semmler 2023-12-10 08:31:06 -05:00
parent 3856dc625a
commit ab1704b883
2 changed files with 16 additions and 1 deletions

View File

@ -62,7 +62,15 @@ MxResult MxCompositePresenter::StartAction(MxStreamController* p_controller, MxD
MxDSAction* action;
if (MxPresenter::StartAction(p_controller, p_action) == SUCCESS) {
while (cursor.Next(action)) {
// The usual cursor.Next() loop doesn't match here, even though
// the logic is the same. It does match when "deconstructed" into
// the following Head(), Current() and NextFragment() calls,
// but this seems unlikely to be the original code.
// The alpha debug build also uses Next().
cursor.Head();
while (cursor.Current(action)) {
cursor.NextFragment();
MxBool success = FALSE;
action->CopyFlags(m_action->GetFlags());

View File

@ -95,6 +95,13 @@ class MxListCursor : public MxCore {
void Reset() { m_match = NULL; }
void Prepend(T p_newobj);
// TODO: Probably shouldn't exist
void NextFragment()
{
if (m_match)
m_match = m_match->GetNext();
}
private:
MxList<T>* m_list;
MxListEntry<T>* m_match;