예제 #1
0
파일: FormMain.cs 프로젝트: jie65535/KeyGo
        private void BtnAdd_Click(object sender, EventArgs e)
        {
            var frm = new FormHotKey();

            if (frm.ShowDialog() == DialogResult.OK)
            {
                AddHotKeyItem(frm.HotKeyItem);
            }
        }
예제 #2
0
파일: FormMain.cs 프로젝트: jie65535/KeyGo
 private void FLPHotKeys_DragDrop(object sender, DragEventArgs e)
 {
     if (e.Data.GetData(DataFormats.FileDrop) is Array files && files.Length > 0)
     {
         var filepath = files.GetValue(0) as string;
         var frm      = new FormHotKey
         {
             HotKeyItem = new HotKeyItem
             {
                 StartupPath = filepath,
             }
         };
         if (frm.ShowDialog() == DialogResult.OK)
         {
             AddHotKeyItem(frm.HotKeyItem);
         }
     }
 }