Ejemplo n.º 1
0
 private void Load_lv_remote()
 {
     if (SshSettings.pwd == null)
     {
         FormPwd fp = new FormPwd();
         if (fp.ShowDialog() == DialogResult.OK)
         {
             GetFileList(listView_remote);
         }
     }
     else
     {
         GetFileList(listView_remote);
     }
 }
Ejemplo n.º 2
0
 private void команднаяСтрокаСервераToolStripMenuItem_Click(object sender, EventArgs e)
 {
     if (SshSettings.pwd == null)
     {
         FormPwd fp = new FormPwd();
         if (fp.ShowDialog() == DialogResult.OK)
         {
             using (FormCmd frm_c = new FormCmd())
             {
                 frm_c.ShowDialog();
             }
         }
     }
     else
     {
         using (FormCmd frm_c = new FormCmd())
         {
             frm_c.ShowDialog();
         }
     }
 }
Ejemplo n.º 3
0
 private static string GetPwdForKeysFile(bool isLoadSettings)
 {
     //Загрузка
     if (isLoadSettings)
     {
         using (FormPwd frm_pwd = new FormPwd(isLoadSettings))
         {
             frm_pwd.ShowDialog();
             return(frm_pwd.Password);
         }
     }
     //Сохранение
     else
     {
         using (FormPwd frm_pwd = new FormPwd(isLoadSettings))
         {
             frm_pwd.MainText = "Задайте пароль на вход";
             frm_pwd.ShowDialog();
             return(frm_pwd.Password);
         }
     }
 }