summaryrefslogtreecommitdiffstats
path: root/src/jrummikub
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2011-05-09 16:05:39 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2011-05-09 16:05:39 +0200
commit90aeaab90050a0f964db567635507bc7fd361db3 (patch)
tree5b04e1843449fda7c3580e34517c2bdb1953a530 /src/jrummikub
parent0d405b9042da7a2a19a339eb42588d2ac27ac366 (diff)
downloadJRummikub-90aeaab90050a0f964db567635507bc7fd361db3.tar
JRummikub-90aeaab90050a0f964db567635507bc7fd361db3.zip
Fix an exception
git-svn-id: svn://sunsvr01.isp.uni-luebeck.de/swproj13/trunk@185 72836036-5685-4462-b002-a69064685172
Diffstat (limited to 'src/jrummikub')
-rw-r--r--src/jrummikub/view/impl/StonePainter.java12
1 files changed, 5 insertions, 7 deletions
diff --git a/src/jrummikub/view/impl/StonePainter.java b/src/jrummikub/view/impl/StonePainter.java
index dccb01d..d6acd09 100644
--- a/src/jrummikub/view/impl/StonePainter.java
+++ b/src/jrummikub/view/impl/StonePainter.java
@@ -94,14 +94,12 @@ class StonePainter {
*/
public void setScale(float scale) {
this.scale = scale;
- prepaint();
- }
- /**
- * @return the current grid scale
- */
- public float getScale() {
- return scale;
+ if (this.scale == 0) {
+ this.scale = 1;
+ }
+
+ prepaint();
}
/**