private async void LoginBtn_Click(object sender, RoutedEventArgs e) { var username = UsernameTextbox.Text; var password = PasswordTextbox.Password; var loggedIn = await UnicontaManager.GetInstance().Login(username, password); if (!loggedIn) { MessageBox.Show("Failed to log in.", "Error"); return; } new LoggedInWindow().Show(); this.Close(); }
public MainWindow() { InitializeComponent(); UnicontaManager.GetInstance().Initialize(); }