- Updating Label observers after a ChangeZone

This commit is contained in:
Sol
2012-02-12 16:55:23 +00:00
parent 9ee6024f6b
commit e256073f22
2 changed files with 13 additions and 0 deletions

View File

@@ -111,6 +111,10 @@ public class GameAction {
public static Card changeZone(final PlayerZone prev, final PlayerZone zone, final Card c) {
if ((prev == null) && !c.isToken()) {
zone.add(c);
Player p = zone.getPlayer();
if (p != null){
p.updateLabelObservers();
}
return c;
}
@@ -190,6 +194,11 @@ public class GameAction {
prev.remove(c);
}
Player p = zone.getPlayer();
if (p != null){
p.updateLabelObservers();
}
final HashMap<String, Object> runParams = new HashMap<String, Object>();
runParams.put("Card", lastKnownInfo);

View File

@@ -2733,6 +2733,10 @@ public abstract class Player extends GameEntity {
public final Object getMustAttackEntity() {
return this.mustAttackEntity;
}
public final void updateLabelObservers() {
this.getZone(Zone.Hand).updateObservers();
}
// //////////////////////////////
//