protected void OnButtonAddClicked(object sender, EventArgs e) { UserDialog userDialog = new UserDialog(interactiveService); userDialog.ShowAll(); if (userDialog.Run() == (int)ResponseType.Ok) { usersModel.UpdateUsers(chkShowInactive.Active); } userDialog.Destroy(); }
private void EditUser() { if (treeviewUsers.GetSelectedObject() is UserBase selectedUser) { UserDialog userDialog = new UserDialog(selectedUser.Id, interactiveService); userDialog.ShowAll(); if (userDialog.Run() == (int)ResponseType.Ok) { usersModel.UpdateUsers(chkShowInactive.Active); } userDialog.Destroy(); } }