示例#1
0
 private static IEnumerable <AFAttributeTemplate> GetAllAttributeTemplatesAndChildren(this AFElementTemplate elementTemplate)
 {
     return(GetAllAttributeTemplatesAndChildren(elementTemplate.GetAllAttributeTemplates()));
 }
示例#2
0
 private void SynchUI()
 {
     try
     {
         if (_rootElement == null)
         {
             if (_rootElementTemplates == null)
             {
                 if (_rootElementTemplate == null)
                 {
                     afTreeView1.SetAFRoot(_database.Elements, null, null);
                 }
                 else
                 {
                     AFNamedCollectionList <AFAttributeTemplate> allAttributeTemplates = _rootElementTemplate.GetAllAttributeTemplates();
                     afTreeView1.SetAFRoot(allAttributeTemplates, null, null);
                 }
             }
             else
             {
                 afTreeView1.SetAFRoot(_rootElementTemplates, null, null);
             }
         }
         else
         {
             afTreeView1.SetAFRoot(_rootElement, null, null);
         }
         //afTreeView1.AfterSelect(null, null);
     }
     catch (Exception ex)
     {
         AFTrace.TraceEvent(ex);
         DrawingHelper.DisplayErrorMessage(this, null, null, ex);
     }
 }