diff options
Diffstat (limited to 'engines/titanic/core/saveable_object.cpp')
-rw-r--r-- | engines/titanic/core/saveable_object.cpp | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/engines/titanic/core/saveable_object.cpp b/engines/titanic/core/saveable_object.cpp index 7522a34737..73b4bf861f 100644 --- a/engines/titanic/core/saveable_object.cpp +++ b/engines/titanic/core/saveable_object.cpp @@ -421,14 +421,14 @@ CSaveableObject *ClassDef::create() { /*------------------------------------------------------------------------*/ -Common::HashMap<Common::String, CSaveableObject::CreateFunction> * - CSaveableObject::_classList = nullptr; -Common::List<ClassDef *> *CSaveableObject::_classDefs; +CSaveableObject::ClassListMap *CSaveableObject::_classList; +CSaveableObject::ClassDefList *CSaveableObject::_classDefs; #define DEFFN(T) CSaveableObject *Function##T() { return new T(); } \ ClassDef *T::_type #define ADDFN(CHILD, PARENT) \ CHILD::_type = new TypeTemplate<CHILD>(#CHILD, PARENT::_type); \ + _classDefs->push_back(CHILD::_type); \ (*_classList)[#CHILD] = Function##CHILD DEFFN(CArm); @@ -835,6 +835,7 @@ DEFFN(CMouseDragMsg); DEFFN(CMouseDragStartMsg); DEFFN(CMouseDragMoveMsg); DEFFN(CMouseDragEndMsg); +DEFFN(CMouseWheelMsg); DEFFN(CMoveToStartPosMsg); DEFFN(CMovieEndMsg); DEFFN(CMovieFrameMsg); @@ -1019,8 +1020,8 @@ DEFFN(CStarControl); DEFFN(CTimeEventInfo); void CSaveableObject::initClassList() { - _classDefs = new Common::List<ClassDef *>(); - _classList = new Common::HashMap<Common::String, CreateFunction>(); + _classDefs = new ClassDefList(); + _classList = new ClassListMap(); ADDFN(CArm, CCarry); ADDFN(CAuditoryCentre, CBrain); ADDFN(CBowlEar, CEar); @@ -1426,6 +1427,7 @@ void CSaveableObject::initClassList() { ADDFN(CMouseDragStartMsg, CMouseDragMsg); ADDFN(CMouseDragMoveMsg, CMouseDragMsg); ADDFN(CMouseDragEndMsg, CMouseDragMsg); + ADDFN(CMouseWheelMsg, CMouseMsg); ADDFN(CMoveToStartPosMsg, CMessage); ADDFN(CMovieEndMsg, CMessage); ADDFN(CMovieFrameMsg, CMessage); @@ -1615,7 +1617,7 @@ void CSaveableObject::initClassList() { } void CSaveableObject::freeClassList() { - Common::List<ClassDef *>::iterator i; + ClassDefList::iterator i; for (i = _classDefs->begin(); i != _classDefs->end(); ++i) delete *i; |