summaryrefslogtreecommitdiffstats
path: root/src/jrummikub/view/impl/AbstractStonePanel.java
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2011-05-10 04:29:15 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2011-05-10 04:29:15 +0200
commitd542d142c89acb9af6e0748c00fe4bc53ee184eb (patch)
tree7332e5fb1095141381fbc173cfaf5aeb7b2d9e1f /src/jrummikub/view/impl/AbstractStonePanel.java
parent39406126081fa7ffa2d5c8e1b18398fcd56be5c2 (diff)
downloadJRummikub-d542d142c89acb9af6e0748c00fe4bc53ee184eb.tar
JRummikub-d542d142c89acb9af6e0748c00fe4bc53ee184eb.zip
Added bling-bling
git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@219 72836036-5685-4462-b002-a69064685172
Diffstat (limited to 'src/jrummikub/view/impl/AbstractStonePanel.java')
-rw-r--r--src/jrummikub/view/impl/AbstractStonePanel.java13
1 files changed, 12 insertions, 1 deletions
diff --git a/src/jrummikub/view/impl/AbstractStonePanel.java b/src/jrummikub/view/impl/AbstractStonePanel.java
index 175f2df..765f6bc 100644
--- a/src/jrummikub/view/impl/AbstractStonePanel.java
+++ b/src/jrummikub/view/impl/AbstractStonePanel.java
@@ -81,6 +81,8 @@ abstract class AbstractStonePanel extends JPanel implements IStonePanel,
- trans.getFirst(), e.getY() - insets.top - trans.getSecond());
setHoveredStone(getStoneAt(pos));
+
+ handleOtherMoveEvent(pos);
}
});
}
@@ -148,7 +150,7 @@ abstract class AbstractStonePanel extends JPanel implements IStonePanel,
}
/**
- * *Overwrite this method* to signal if special zone was clicked
+ * Overwrite this method to signal if special zone was clicked
*
* @param pos
* the clicked position
@@ -159,6 +161,15 @@ abstract class AbstractStonePanel extends JPanel implements IStonePanel,
return false;
}
+ /**
+ * Overwrite this method to signal if special zone was hovered
+ *
+ * @param pos
+ * the hovered position
+ */
+ protected void handleOtherMoveEvent(Position pos) {
+ }
+
private Stone getStoneAt(Position pos) {
for (Pair<Stone, Position> entry : stones) {
Stone stone = entry.getFirst();