CTree Class Reference

#include <srTree.h>

List of all members.

Public Member Functions

CString GetSelectedObject () const
void WriteLayout ()
CDocGetDocument ()
virtual void OnInitialUpdate ()

Protected Member Functions

 CTree ()
virtual void OnUpdate (CView *pSender, LPARAM lHint, CObject *pHint)
virtual ~CTree ()
afx_msg void OnHelp ()
afx_msg void OnRButtonUp (UINT nFlags, CPoint point)
afx_msg void OnRButtonDown (UINT nFlags, CPoint point)
afx_msg void OnViewSelected ()
afx_msg void OnUpdateViewSelected (CCmdUI *pCmdUI)
afx_msg void OnLButtonDblClk (UINT nFlags, CPoint point)

Private Member Functions

void InsertObject (std::vector< ObjectDescription >::const_iterator &iter, HTREEITEM hParent)
CString GetNameFromItem (HTREEITEM hItem) const
HTREEITEM GetItemFromName2 (CString s, HTREEITEM hItem) const
HTREEITEM GetItemFromName (CString s) const
bool RestoreLayout ()

Private Attributes

CMenu m_menuPopup
CImageList m_ImageList
CString m_sSelected


Detailed Description

Definition at line 7 of file srTree.h.


Constructor & Destructor Documentation

CTree::CTree (  )  [protected]

Definition at line 20 of file srTree.cpp.

CTree::~CTree (  )  [protected, virtual]

Definition at line 24 of file srTree.cpp.


Member Function Documentation

CDoc * CTree::GetDocument (  )  [inline]

Definition at line 68 of file srTree.h.

Referenced by InsertObject(), OnUpdate(), OnUpdateViewSelected(), OnViewSelected(), RestoreLayout(), and WriteLayout().

HTREEITEM CTree::GetItemFromName ( CString  s  )  const [private]

Definition at line 173 of file srTree.cpp.

References GetItemFromName2().

Referenced by OnUpdate().

HTREEITEM CTree::GetItemFromName2 ( CString  s,
HTREEITEM  hItem 
) const [private]

Definition at line 151 of file srTree.cpp.

Referenced by GetItemFromName().

CString CTree::GetNameFromItem ( HTREEITEM  hItem  )  const [private]

Definition at line 138 of file srTree.cpp.

Referenced by GetSelectedObject(), and OnUpdate().

CString CTree::GetSelectedObject (  )  const

Definition at line 178 of file srTree.cpp.

References ASSERT, and GetNameFromItem().

Referenced by OnViewSelected(), and WriteLayout().

void CTree::InsertObject ( std::vector< ObjectDescription >::const_iterator &  iter,
HTREEITEM  hParent 
) [private]

Definition at line 107 of file srTree.cpp.

References GetDocument(), OBJECT_TYPE_ACTUATORPORT, OBJECT_TYPE_NONE, OBJECT_TYPE_OBJECT, and OBJECT_TYPE_SENSORPORT.

Referenced by OnUpdate().

void CTree::OnHelp (  )  [protected]

Definition at line 246 of file srTree.cpp.

void CTree::OnInitialUpdate (  )  [virtual]

Definition at line 189 of file srTree.cpp.

References IDB_TREE, IDP_TREE, m_ImageList, m_menuPopup, and RestoreLayout().

void CTree::OnLButtonDblClk ( UINT  nFlags,
CPoint  point 
) [protected]

Definition at line 288 of file srTree.cpp.

References OnViewSelected().

void CTree::OnRButtonDown ( UINT  nFlags,
CPoint  point 
) [protected]

Definition at line 230 of file srTree.cpp.

void CTree::OnRButtonUp ( UINT  nFlags,
CPoint  point 
) [protected]

Definition at line 234 of file srTree.cpp.

References m_menuPopup.

void CTree::OnUpdate ( CView *  pSender,
LPARAM  lHint,
CObject *  pHint 
) [protected, virtual]

Definition at line 207 of file srTree.cpp.

References GetDocument(), GetItemFromName(), GetNameFromItem(), CDoc::GetObjectDescriptionTree(), InsertObject(), m_sSelected, and UPDATE_SUCCESS.

void CTree::OnUpdateViewSelected ( CCmdUI *  pCmdUI  )  [protected]

Definition at line 283 of file srTree.cpp.

References GetDocument().

void CTree::OnViewSelected (  )  [protected]

Definition at line 263 of file srTree.cpp.

References CApp::CreateActuator(), CApp::CreateObject(), CApp::CreateSensor(), GetDocument(), GetSelectedObject(), CDoc::GetSimulation(), OBJECT_TYPE_ACTUATORPORT, OBJECT_TYPE_OBJECT, and OBJECT_TYPE_SENSORPORT.

Referenced by OnLButtonDblClk().

bool CTree::RestoreLayout (  )  [private]

Definition at line 50 of file srTree.cpp.

References GetDocument(), CDoc::IsRestoringLayout(), m_sSelected, CDoc::NewSection(), CDoc::ReadInt(), and CDoc::ReadString().

Referenced by OnInitialUpdate().

void CTree::WriteLayout (  ) 

Definition at line 28 of file srTree.cpp.

References GetDocument(), GetSelectedObject(), CDoc::GetSimulation(), m_sSelected, CDoc::NewSection(), CDoc::WriteInt(), and CDoc::WriteString().


Member Data Documentation

CImageList CTree::m_ImageList [private]

Definition at line 11 of file srTree.h.

Referenced by OnInitialUpdate().

CMenu CTree::m_menuPopup [private]

Definition at line 10 of file srTree.h.

Referenced by OnInitialUpdate(), and OnRButtonUp().

CString CTree::m_sSelected [private]

Definition at line 12 of file srTree.h.

Referenced by OnUpdate(), RestoreLayout(), and WriteLayout().


The documentation for this class was generated from the following files:
Generated on Thu Dec 7 01:26:20 2006 for DT2005.panorama by  doxygen 1.4.7