public string AskUnlockPassword(bool authFailed) { if (this.InvokeRequired) { AskUnlockPasswordDelegate inv = new AskUnlockPasswordDelegate(this.AskUnlockPassword); return((string)this.Invoke(inv, new object[] { authFailed })); } else { Forms.WindowUnlock dlg = new Forms.WindowUnlock(); dlg.AuthFailed = authFailed; dlg.ShowDialog(UiClient.Instance.SplashWindow); return(dlg.Body); } }
public string AskUnlockPassword(bool authFailed) { try { if (this.InvokeRequired) { AskUnlockPasswordDelegate inv = new AskUnlockPasswordDelegate(this.AskUnlockPassword); return((string)this.Invoke(inv, new object[] { authFailed })); } else { Forms.WindowUnlock dlg = new Forms.WindowUnlock(); dlg.AuthFailed = authFailed; dlg.ShowDialog(UiClient.Instance.SplashWindow); return(dlg.Body); } } catch (Exception ex) { Engine.Instance.Logs.LogUnexpected(ex); return(""); } }