void CAttributeNode::operator()(ATTRSTATE state) { if (GetTreeView()) { SetState(-1, TVIS_STATEIMAGEMASK); SetState(INDEXTOSTATEIMAGEMASK(GetStateIcon(state)), TVIS_STATEIMAGEMASK); } }
void CModuleNode::operator()(IModule * /*module*/) { if (GetTreeView()) { SetState(-1, TVIS_STATEIMAGEMASK); SetState(INDEXTOSTATEIMAGEMASK(GetStateIcon(GetState())), TVIS_STATEIMAGEMASK); } }
void CAttributeNode::operator()(IAttribute * /*attr*/, bool eclChanged, IAttribute * newAttrAsOldOneMoved, bool deleted) { if (GetTreeView()) { if (newAttrAsOldOneMoved || deleted) Delete(); else { GenerateDispText(); SetState(-1, TVIS_STATEIMAGEMASK); SetState(INDEXTOSTATEIMAGEMASK(GetStateIcon(GetState())), TVIS_STATEIMAGEMASK); } } }
void CAttributeHistoryNode::operator()(IAttribute * /*attr*/, bool eclChanged, IAttribute * newAttrAsOldOneMoved, bool deleted) { if (GetTreeView()) { GenerateDispText(); bool isCurrentVersion = (m_attributeHistory->GetVersion() == m_attributeHistory->GetAttribute()->GetVersion()); SetState(-1, TVIS_STATEIMAGEMASK); SetState(INDEXTOSTATEIMAGEMASK(GetStateIcon(isCurrentVersion ? m_attributeHistory->GetAttribute()->GetState() : ATTRSTATE_NONE)), TVIS_STATEIMAGEMASK); } //TODO handle renamed and deleted. ATLASSERT(!newAttrAsOldOneMoved && !deleted); //CString modfiedDate(m_attributeHistory->GetModifiedDate()); //if( modfiedDate.IsEmpty() ) //{ // SetState(INDEXTOSTATEIMAGEMASK(ATTRSTATE_NONE), TVIS_STATEIMAGEMASK); //} //GenerateDispText(); }
LRESULT CRepositoryView::OnRefreshModuleNode(UINT /*uMsg*/, WPARAM wParam, LPARAM lParam) { CModuleNode * node = (CModuleNode *)wParam; if (node && node->GetTreeView() && node->GetTreeView()->IsWindow()) { node->SetState(-1, TVIS_STATEIMAGEMASK); node->SetState(INDEXTOSTATEIMAGEMASK(GetStateIcon(node->GetState())), TVIS_STATEIMAGEMASK); switch (lParam) { case REFRESH_MODULE_CHILDADDED: if (node->IsExpanded()) { node->Expand(TVE_COLLAPSE | TVE_COLLAPSERESET); node->Expand(); } break; } node->Release(); } return 0; }
Add(wxS("namespace"), GetNamespaceIcon()); Add(wxS("operation"), GetOperationIcon()); Add(wxS("overrides"), GetOverridesIcon()); Add(wxS("package"), GetPackageIcon()); Add(wxS("parameter"), GetParameterIcon()); Add(CODE_PYTHON, GetPythonIcon()); Add(CODE_PHP, GetPHPIcon()); Add(wxS("private"), GetPrivateIcon()); Add(wxS("protected"), GetProtectedIcon()); Add(wxS("public"), GetPublicIcon()); Add(wxS("relation"), GetRelationIcon()); Add(wxS("inrelation"), wxBitmap(GetRelationIcon().ConvertToImage().Mirror(false))); Add(wxS("selftransition"), GetSelftransitionIcon()); Add(wxS("sequence"), GetSequenceIcon()); Add(wxS("statechart"), GetStatechartIcon()); Add(wxS("state"), GetStateIcon()); Add(wxS("static"), GetStaticIcon()); Add(wxS("terminate"), GetTerminateIcon()); Add(wxS("traced"), GetTracedIcon()); Add(wxS("tracable"), GetTracableIcon()); Add(wxS("transition"), GetTransitionIcon()); Add(wxS("type"), GetTypeIcon()); Add(wxS("usecasediagram"), GetUsecasediagramIcon()); Add(wxS("virtual"), GetVirtualIcon()); Add(wxS("website"), GetWebsiteIcon()); Add(wxS("inputparameter"), GetInputParameter()); Add(wxS("outputparameter"), GetOutputParameter()); Add(wxS("inoutparameter"), GetInOutParameter()); Add(wxS("port"), GetPortIcon()); Add(wxS("delegate"), GetDelegateIcon()); Add(wxS("found"), GetFoundIcon());