/// <summary> /// Handles change requests to the current global credentials of the application. /// </summary> /// <param name="sender">The sender of the request.</param> /// <param name="args">The arguments specifying the new credentials.</param> private void ChangeCredentials(object sender, CredentialsChangeArgs args) { credentials = args.Credentials; Cursor.Current = Cursors.WaitCursor; RentItUserControl nextScreen = new MainScreen { RentItProxy = this.rentItProxy, Credentials = this.credentials }; ChangeContent(sender, new ContentChangeArgs(nextScreen, "RentIt")); Cursor.Current = Cursors.Default; TopBar.Credentials = this.credentials; }
/// <summary> /// For propagating the MainForms subscription to the CredentialsChangeEvent /// to the RentItUserControl's inner RentItUserControls. /// </summary> protected void CredentialsChangeEventPropagated(object obj, CredentialsChangeArgs e) { FireCredentialsChangeEvent(e.Credentials); }