using System; using System.Windows.Forms; namespace AIProofread.Controls { public partial class FormLogin : Form { public event EventHandler OnLoginCompleted; public FormLogin() { InitializeComponent(); Bridge.InitWebEnvAsync("login", web); Bridge.AddEventHandler(BridgeEvent.LoginSuccess, OnLoginSuccess); } private void OnLoginSuccess(object sender, EventArgs e) { OnLoginCompleted?.Invoke(this, e); } private void FormLogin_Load(object sender, EventArgs e) { this.web.Source = new Uri(Config.WebPath("#login")); } } }