Browse Source

Little fix in highlight in CGarrisonSlot.

FeniksFire 8 years ago
parent
commit
68c618cb99
1 changed files with 8 additions and 5 deletions
  1. 8 5
      client/widgets/CGarrisonInt.cpp

+ 8 - 5
client/widgets/CGarrisonInt.cpp

@@ -514,11 +514,14 @@ void CGarrisonInt::setSplittingMode(bool on)
 
 	if (inSplittingMode || on)
 	{
-		for(CGarrisonSlot * slot : slotsUp)
-			slot->setHighlight( ( on && (slot->our() || slot->ally()) && (slot->creature == nullptr || slot->creature == getSelection()->creature)));
-
-		for(CGarrisonSlot * slot : slotsDown)
-			slot->setHighlight( ( on && (slot->our() || slot->ally()) && (slot->creature == nullptr || slot->creature == getSelection()->creature)));
+		for(CGarrisonSlot * slot : slotsUp){
+			if(slot!=getSelection())
+				slot->setHighlight( ( on && (slot->our() || slot->ally()) && (slot->creature == nullptr || slot->creature == getSelection()->creature)));
+		}
+		for(CGarrisonSlot * slot : slotsDown){
+			if(slot!=getSelection())
+				slot->setHighlight( ( on && (slot->our() || slot->ally()) && (slot->creature == nullptr || slot->creature == getSelection()->creature)));
+		}
 		inSplittingMode = on;
 	}
 }