Skip to content

Commit

Permalink
fixed crash on setting pet name on unselected pet
Browse files Browse the repository at this point in the history
  • Loading branch information
tolik518 committed Aug 5, 2024
1 parent 3c4bae2 commit ea33473
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions SoG_SGreader/Forms/FrmMain.cs
Original file line number Diff line number Diff line change
Expand Up @@ -814,8 +814,11 @@ private void LstPets_SelectedIndexChanged(object sender, EventArgs e)
{
if (lstPets.FocusedItem == null)
{
txtPetNickname.Enabled = false;
return;
}
txtPetNickname.Enabled = true;


int index = lstPets.FocusedItem.Index;
numPetHP.Value = Int32.Parse(lstPets.Items[index].SubItems[2].Text);
Expand Down

0 comments on commit ea33473

Please sign in to comment.