public static void Main(string[] args) { BasePath = Path.Combine( Environment.GetFolderPath(Environment.SpecialFolder.LocalApplicationData), "NTranslate" ); Directory.CreateDirectory(BasePath); Application.EnableVisualStyles(); Application.SetCompatibleTextRenderingDefault(false); MouseWheelMessageFilter.Install(); SpellCheck = new SpellCheck.SpellCheck(); SolutionManager = new SolutionManager(); MainForm = new MainForm(args); DocumentManager = new DocumentManager(); Application.Run(MainForm); }
public ProjectExplorerForm(MainForm mainForm) { if (mainForm == null) throw new ArgumentNullException("mainForm"); _mainForm = mainForm; InitializeComponent(); VisualStyleUtil.StyleTreeView(_treeView); _imageList = new ImageListManager(); _treeView.ImageList = _imageList.ImageList; _overlays.Add(OverlayImage.Incomplete, _treeView.ImageList.Images.Count); _imageList.ImageList.Images.Add(NeutralResources.IncompleteOverlay); _overlays.Add(OverlayImage.Complete, _treeView.ImageList.Images.Count); _imageList.ImageList.Images.Add(NeutralResources.CompleteOverlay); FolderImageIndex = GetFolderImageIndex(); Program.SolutionManager.CurrentSolutionChanged += SolutionManager_CurrentSolutionChanged; mainForm.DockPanel.ActiveContentChanged += DockPanel_ActiveContentChanged; }