public MainForm(MainFormController controller) { InitializeComponent(); this.elementHost.Child = new DiagramViewer(); mainController = controller; mainController.Initialize(this); AssemblyTree = new DTreeNode<DTreeItem>(); }
private static void RunConsole(MainFormController controller, CommandLineArguments args) { if (args == null) { throw new ArgumentNullException("args"); } AppDomain.CurrentDomain.UnhandledException += CurrentDomainOnUnhandledException; Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(new ConsoleView(controller, args)); }
public ConsoleView(MainFormController controller, CommandLineArguments args) { this.InitializeComponent(); this.Visible = false; this.Controller = controller; this._assemblyName = args.AssemblyName; this.TypeName = args.TypeName; this.DestinationPath = args.DestinationPath; // Override config settings. Settings.OutputType = args.OutputType; Settings.IncludeAssemblyReferences = args.IncludeReferenceAssemblies; this.Controller.Initialize(this); }
private static void Run(string[] args) { var controller = new MainFormController(); bool consoleOnly = false; if (args.Length > 0) { CommandLineArguments cla = CommandLineArguments.ParseArguments(args); if (cla != null) { RunConsole(controller, cla); } consoleOnly = CommandLineArguments.ConsoleOnly; } if (!consoleOnly) { RunGUI(controller); } }
private static void RunGUI(MainFormController controller) { Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); Application.Run(new MainForm(controller)); }