Changeset 650
- Timestamp:
- 11/21/06 13:57:39 (2 years ago)
- Location:
- trunk/common
- Files:
-
- 2 modified
-
project.cpp (modified) (5 diffs)
-
project.h (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/common/project.cpp
r649 r650 324 324 m_PlayingAnimation = false; 325 325 326 m_ActiveModel = new lcModel("Main");327 m_ModelList.Add( m_ActiveModel);328 S ystemUpdateModelMenu(m_ModelList, m_ActiveModel);326 lcModel* Model = new lcModel("Main"); 327 m_ModelList.Add(Model); 328 SetActiveModel(Model); 329 329 330 330 for (i = 0; i < m_ViewList.GetSize (); i++) … … 3070 3070 // Project functions 3071 3071 3072 void Project::SetActiveModel(lcModel* Model) 3073 { 3074 m_ActiveModel = Model; 3075 3076 SystemUpdateModelMenu(m_ModelList, m_ActiveModel); 3077 UpdateSelection(); 3078 UpdateAllViews(); 3079 } 3080 3072 3081 void Project::AddPiece(Piece* NewPiece) 3073 3082 { … … 4434 4443 lcModel* Model = new lcModel(Name); 4435 4444 m_ModelList.Add(Model); 4436 m_ActiveModel = Model;4445 SetActiveModel(Model); 4437 4446 4438 4447 SetModifiedFlag(true); … … 4459 4468 m_ModelList.RemovePointer(m_ActiveModel); 4460 4469 delete m_ActiveModel; 4461 m_ActiveModel = m_ModelList[0];4470 SetActiveModel(m_ModelList[0]); 4462 4471 4463 4472 SetModifiedFlag(true); … … 4490 4499 if (Index < m_ModelList.GetSize()) 4491 4500 { 4492 m_ActiveModel = m_ModelList[Index]; 4493 SystemUpdateModelMenu(m_ModelList, m_ActiveModel); 4494 UpdateAllViews(); 4501 SetActiveModel(m_ModelList[Index]); 4495 4502 } 4496 4503 } break; -
trunk/common/project.h
r646 r650 171 171 CONNECTION_TYPE m_pConnections[LC_CONNECTIONS]; 172 172 173 void SetActiveModel(lcModel* Model); 173 174 void AddPiece(Piece* pPiece); 174 175 void RemovePiece(Piece* pPiece);
