1、添加2个自定义控件:chartTC、TreeViewTc; 2、修复了一些bug,完善了功能;3、更新了gitignore,将bin等目录忽略;

This commit is contained in:
tangchao0503
2022-06-16 13:26:55 +08:00
parent b43227dc58
commit f36c5eaa39
50 changed files with 13043 additions and 3770 deletions

View File

@ -50,15 +50,42 @@ namespace mainProgram
return;
}
//做判断:
DialogResult re = MessageBox.Show("删除工程路径下所有内容?", "提示", MessageBoxButtons.OKCancel, MessageBoxIcon.Exclamation);
if (re == DialogResult.Cancel)
{
return;
}
//创建工程
ProjectManager projectManager = new ProjectManager(projectPath);
projectManager.CreateProject(calFilePath, dataPath);
int value = projectManager.CreateProject(calFilePath, dataPath);
TransferEvent(projectManager);//触发事件
switch (value)
{
case 0:
TransferEvent(projectManager);//触发事件
MessageBox.Show(this, "工程创建成功!", "提示");
MessageBox.Show(this, "工程创建成功!", "提示");
this.DialogResult = DialogResult.OK;
Close();//创建工程完成后,关闭窗口
this.DialogResult = DialogResult.OK;
Close();//创建工程完成后,关闭窗口
break;
case 1:
MessageBox.Show(this, "定标文件夹有错!", "提示");
break;
case 2:
MessageBox.Show(this, "数据文件夹有错!", "提示");
break;
case 3:
MessageBox.Show(this, "工程路径有错!", "提示");
break;
default: /* 可选的 */
break;
}
}
private void SelectDataPathBtn_Click(object sender, EventArgs e)
@ -81,19 +108,32 @@ namespace mainProgram
private void SelectProjectPathBtn_Click(object sender, EventArgs e)
{
FolderBrowserDialog dialog = new FolderBrowserDialog();
dialog.Description = "请选择工程文件夹";
if (dialog.ShowDialog() == DialogResult.OK)
{
if (string.IsNullOrEmpty(dialog.SelectedPath))
{
MessageBox.Show(this, "文件夹路径不能为空", "提示");
return;
}
string savePath = dialog.SelectedPath;
ProjectPathTextBox.Text = savePath;
//FolderBrowserDialog dialog = new FolderBrowserDialog();
//dialog.Description = "请选择工程文件夹";
//if (dialog.ShowDialog() == DialogResult.OK)
//{
// if (string.IsNullOrEmpty(dialog.SelectedPath))
// {
// MessageBox.Show(this, "文件夹路径不能为空", "提示");
// return;
// }
// string savePath = dialog.SelectedPath;
// ProjectPathTextBox.Text = savePath;
//}
OpenFileDialog dialog = new OpenFileDialog();
dialog.CheckFileExists = false; //设置不弹出警告
//dialog.Multiselect = true;//该值确定是否可以选择多个文件
dialog.Title = "请输入工程名";
dialog.Filter = "所有文件(*.*)|*.*";
if (dialog.ShowDialog() == System.Windows.Forms.DialogResult.OK)
{
string filePath = dialog.FileName;
filePath = filePath + ".EasySif";
ProjectPathTextBox.Text = filePath;
}
}
private void Cancel_Click(object sender, EventArgs e)