Ejemplo n.º 1
0
        private void btnStart_Click(object sender, EventArgs e)
        {
            var arg = new ProjectScanSettings(txtImportRoot.Text,
                                              txtBaseSccPath.Text,
                                              cbCsProj.Checked,
                                              cbVcProj.Checked,
                                              cbDspProj.Checked,
                                              BuildFile);

            ProjectScanProgressForm.Start(arg);
            this.Close();
        }
Ejemplo n.º 2
0
        public static void Start(ProjectScanSettings conf)
        {
            if (conf == null)
            {
                return;
            }

            var f = new ProjectScanProgressForm();

            f._worker.DoWork += f.DoScanProjects;
            f._worker.RunWorkerAsync(conf);
            f._worker.RunWorkerCompleted        += f.WorkerRunWorkerCompleted;
            f._worker.ProgressChanged           += f.WorkerProgressChanged;
            f._worker.WorkerSupportsCancellation = true;
            f._worker.WorkerReportsProgress      = true;
            f.ShowDialog();
        }
Ejemplo n.º 3
0
        private static void FindProjects(string path, ProjectScanSettings settings)
        {
            if (settings.CppProjects)
            {
                var arr = Directory.GetFiles(path, "*.vcproj", SearchOption.AllDirectories);
                lock (settings)
                    settings.Filenames.AddRange(arr);
            }

            if (settings.CsProjects)
            {
                var arr = Directory.GetFiles(path, "*.csproj", SearchOption.AllDirectories);
                lock (settings)
                    settings.Filenames.AddRange(arr);
            }

            if (settings.DspProjects)
            {
                var arr = Directory.GetFiles(path, "*.dsp", SearchOption.AllDirectories);
                lock (settings)
                    settings.Filenames.AddRange(arr);
            }
        }