private void CreateDiagramFunction(object o) { string[] arguments = o as string[]; string vhdFile = arguments[0]; string EntityName = arguments[1]; string ArchitectureName = arguments[2]; string vcdFile = arguments[3]; PrepareCompilator(); compiler.Messages.Clear(); bool res = compiler.CreateDiagram(vhdFile, EntityName, ArchitectureName, vcdFile); project.UpdateSimulationFolderContent(); bool isContainsFile = false; foreach (Schematix.ProjectExplorer.Waveform_File w in project.GetProjectElements <Schematix.ProjectExplorer.Waveform_File>()) { if (w.Path == vcdFile) { isContainsFile = true; break; } } if (isContainsFile == false) { Schematix.ProjectExplorer.ProjectElementBase vhdl = core.SearchItemInSolution(vhdFile); Schematix.ProjectExplorer.ProjectFolder folder = vhdl.Parent as Schematix.ProjectExplorer.ProjectFolder; Schematix.ProjectExplorer.ProjectElement vcd = Schematix.ProjectExplorer.ProjectElement.CreateProjectElementByPath(vcdFile, folder); folder.AddElement(vcd); } if (System.IO.File.Exists(vcdFile) == true) { core.SaveSolution(); core.UpdateExplorerPanel(); Schematix.Windows.Waveform.Waveform waveformWindow = core.OpenNewWindow(vcdFile, true) as Schematix.Windows.Waveform.Waveform; waveformWindow.SetParameters(vhdFile, EntityName, ArchitectureName); waveformWindow.Save(); } }
/// <summary> /// Конструктор /// </summary> /// <param name="path"></param> /// <param name="parent"></param> public FSM_File(string path, ProjectElement parent) : base(path, parent) { parentProjectElement = parent; }
/// <summary> /// Конструктор /// </summary> /// <param name="path"></param> /// <param name="parent"></param> public VHDL_Code_File(string path, ProjectElement parent) : base(path, parent) { parentProjectElement = parent; }
/// <summary> /// Конструктор /// </summary> /// <param name="path"></param> /// <param name="parent"></param> public Waveform_File(string path, ProjectElement parent) : base(path, parent) { parentProjectElement = parent; }
/// <summary> /// Конструктор /// </summary> /// <param name="path"></param> /// <param name="parent"></param> public ProjectFolder(string path, ProjectElement parent) : base(path, parent) { parentProjectElement = parent; childrens = new List <ProjectElement>(); }