summaryrefslogtreecommitdiffstats
path: root/src/jrummikub/view/impl/Board.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/jrummikub/view/impl/Board.java')
-rw-r--r--src/jrummikub/view/impl/Board.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/jrummikub/view/impl/Board.java b/src/jrummikub/view/impl/Board.java
index b6d92a8..94571e0 100644
--- a/src/jrummikub/view/impl/Board.java
+++ b/src/jrummikub/view/impl/Board.java
@@ -20,6 +20,9 @@ import jrummikub.model.Position;
import jrummikub.model.Stone;
import jrummikub.view.IBoard;
+/**
+ * Implementation of the board
+ */
@SuppressWarnings("serial")
class Board extends StonePanel implements IBoard {
private final static int BOARD_HEIGHT = 2;
@@ -39,6 +42,9 @@ class Board extends StonePanel implements IBoard {
private Map<Stone, Position> stones = Collections.emptyMap();
private Collection<Stone> selectedStones = Collections.emptyList();
+ /**
+ * Creates a new Board instance
+ */
Board() {
setBorder(new MatteBorder(0, 1, 0, 1, Color.DARK_GRAY));
@@ -103,7 +109,13 @@ class Board extends StonePanel implements IBoard {
repaint();
}
- public void setSelectedStones(Collection<Stone> stones) {
+ /**
+ * Sets the stones that are to be painted selected
+ *
+ * @param stones
+ * the selected stones
+ */
+ void setSelectedStones(Collection<Stone> stones) {
selectedStones = stones;
repaint();
}