mirror of
https://github.com/kwsch/PKHeX.git
synced 2026-09-11 17:55:17 -05:00
Fix dragging battle team slot sprite refresh
Refresh the image if the team slot indication needs updating (true->false, false->true), else stay lazy and just set the image. Could just refresh the image regardless but muh negligible speed
This commit is contained in:
@@ -4121,7 +4121,12 @@ private void pbBoxSlot_MouseMove(object sender, MouseEventArgs e)
|
||||
pb.BackgroundImage = null;
|
||||
|
||||
if (DragInfo.SameBox && DragInfo.DestinationValid)
|
||||
SlotPictureBoxes[DragInfo.slotDestinationSlotNumber].Image = img;
|
||||
{
|
||||
if (SAV.getIsTeamSet(box, DragInfo.slotDestinationSlotNumber) ^ SAV.getIsTeamSet(box, DragInfo.slotSourceSlotNumber))
|
||||
getQuickFiller(SlotPictureBoxes[DragInfo.slotDestinationSlotNumber], SAV.getStoredSlot(DragInfo.slotDestinationOffset));
|
||||
else
|
||||
SlotPictureBoxes[DragInfo.slotDestinationSlotNumber].Image = img;
|
||||
}
|
||||
|
||||
if (result == DragDropEffects.Copy) // viewed in tabs, apply 'view' highlight
|
||||
getSlotColor(DragInfo.slotSourceSlotNumber, Resources.slotView);
|
||||
|
||||
@@ -203,7 +203,12 @@ private void pbBoxSlot_MouseMove(object sender, MouseEventArgs e)
|
||||
pb.BackgroundImage = null;
|
||||
|
||||
if (DragInfo.SameBox && DragInfo.DestinationValid)
|
||||
SlotPictureBoxes[DragInfo.slotDestinationSlotNumber].Image = img;
|
||||
{
|
||||
if (SAV.getIsTeamSet(box, DragInfo.slotDestinationSlotNumber) ^ SAV.getIsTeamSet(box, DragInfo.slotSourceSlotNumber))
|
||||
getQuickFiller(SlotPictureBoxes[DragInfo.slotDestinationSlotNumber], SAV.getStoredSlot(DragInfo.slotDestinationOffset));
|
||||
else
|
||||
SlotPictureBoxes[DragInfo.slotDestinationSlotNumber].Image = img;
|
||||
}
|
||||
}
|
||||
catch (Exception x)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user