void itemsListBox_SelectedIndexChanged(object sender, EventArgs e) { selected = (ItemsItem)itemsListBox.SelectedItem; character.Gear[WoWHelper.Slot(slot)] = selected; if (selected.Name == "None") { cosmeticTooltip.Hide(itemsListBox); } else { cosmeticTooltip.Item = selected; cosmeticTooltip.Show(selected.Name, itemsListBox, itemsListBox.Size.Width + 6 + openGLControl.Width, 0); } }
void itemsListBox_SelectedIndexChanged(object sender, EventArgs e) { selected = (ItemsItem)itemsListBox.SelectedItem; character.Gear[WoWHelper.Slot(slot)] = selected; if (shieldRadioButton.Checked) { weaponTooltip.Hide(itemsListBox); heldInOffHandTooltip.Hide(itemsListBox); if (selected.Name == "None") { shieldTooltip.Hide(itemsListBox); } else { shieldTooltip.Item = selected; shieldTooltip.Show(selected.Name, itemsListBox, itemsListBox.Size.Width + 6 + openGLControl.Width, 0); } } else if (heldInOffHandRadioButton.Checked) { weaponTooltip.Hide(itemsListBox); shieldTooltip.Hide(itemsListBox); if (selected.Name == "None") { heldInOffHandTooltip.Hide(itemsListBox); } else { heldInOffHandTooltip.Item = selected; heldInOffHandTooltip.Show(selected.Name, itemsListBox, itemsListBox.Size.Width + 6 + openGLControl.Width, 0); } } else { shieldTooltip.Hide(itemsListBox); heldInOffHandTooltip.Hide(itemsListBox); if (selected.Name == "None") { weaponTooltip.Hide(itemsListBox); } else { weaponTooltip.Item = selected; weaponTooltip.Show(selected.Name, itemsListBox, itemsListBox.Size.Width + 6 + openGLControl.Width, 0); } } }