Пример #1
0
 private void imgIcon_MouseClick(object sender, MouseEventArgs e)
 {
     if (e.Button == MouseButtons.Right && Program.api.AppIcon != null)//判断你点的是不是右键
     {
         if (Fbd.ShowDialog() == DialogResult.OK)
         {
             //记录选中的目录
             Program.api.SavePath = Fbd.SelectedPath;
             RunAsync(() => {
                 Program.api.SaveIcon(Program.api.IconPath);
             });
         }
     }
 }
Пример #2
0
        private void ExportResBtn_Click(object sender, EventArgs e)
        {
            if (!string.IsNullOrEmpty(ExportPath))
            {
                //设置此次默认目录为上一次选中目录
                Fbd.SelectedPath = ExportPath;
            }

            if (Fbd.ShowDialog() == DialogResult.OK)
            {
                //记录选中的目录
                ExportPath = Fbd.SelectedPath;
                RunAsync(() => {
                    ExportResXml(ExportPath);
                });
            }


            OnExportResSuccess = () => {
                RunInMainthread(() => {
                    MessageBox.Show("已导出!");
                });
            };
        }
Пример #3
0
        private void SaveItemMenu_Click(object sender, EventArgs e)
        {
            if (!string.IsNullOrEmpty(Program.api.SavePath))
            {
                //设置此次默认目录为上一次选中目录
                Fbd.SelectedPath = Program.api.SavePath;
            }

            if (Fbd.ShowDialog() == DialogResult.OK)
            {
                //记录选中的目录
                Program.api.SavePath = Fbd.SelectedPath;
                RunAsync(() => {
                    Program.api.SaveSelect(selectedpath);
                });
            }


            Program.api.OnExtractSuccess = () => {
                RunInMainthread(() => {
                    MessageBox.Show("已导出!");
                });
            };
        }