From ec54bde90aad27a5ec4bc7bfec6cef732c7c3348 Mon Sep 17 00:00:00 2001 From: Jannis Harder Date: Sun, 19 Jun 2011 23:42:19 +0200 Subject: Show heap size in side panel git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@497 72836036-5685-4462-b002-a69064685172 --- src/jrummikub/control/RoundControl.java | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'src/jrummikub/control') diff --git a/src/jrummikub/control/RoundControl.java b/src/jrummikub/control/RoundControl.java index f209f3e..285980a 100644 --- a/src/jrummikub/control/RoundControl.java +++ b/src/jrummikub/control/RoundControl.java @@ -203,12 +203,15 @@ public class RoundControl { } void deal() { + view.getSidePanel().setHeapCapacity(roundState.getGameHeap().getSize()); for (int i = 0; i < roundState.getPlayerCount(); i++) { IHand hand = roundState.getNthNextPlayer(i).getHand(); for (int j = 0; j < roundState.getGameSettings().getNumberOfStonesDealt(); j++) { hand.drop(roundState.getGameHeap().drawStone(), new Position(0, 0)); } } + view.getSidePanel().setHeapSize(roundState.getGameHeap().getSize()); + } private boolean laidOutValidPoints() { @@ -392,6 +395,8 @@ public class RoundControl { hand.drop(roundState.getGameHeap().drawStone(), new Position( Hand.WIDTH - 1, rowCount - 1)); } + + view.getSidePanel().setHeapSize(roundState.getGameHeap().getSize()); } private void dealStone() { -- cgit v1.2.3