コード例 #1
0
 private void AddPanelHolder(int id, string name, PanelLoadType corner)
 {
     PanelHolders.Add(new PanelHolderViewModel()
     {
         Id = id, Name = name, Corner = corner
     });
 }
        protected override void AddElement(IEnumerable <IMachineElement> elements)
        {
            foreach (var item in elements)
            {
                if (item is PanelHolderElementViewModel ph)
                {
                    PanelHolders.Add(new PanelHolderManagerViewModel()
                    {
                        Id     = ph.PanelHolderId,
                        Name   = ph.Name,
                        Corner = ph.Corner
                    });
                }

                AddElement(item.Children);
            }
        }