public class DrawController {
+ protected static final int IMAGE_COPY_HEIGHT = 25;
+
protected final Map<TileConfigModel, Integer> remaining;
protected TileConfigModel currentTile;
protected Random randSrc;
remaining = models.stream()
.collect(Collectors.toMap(
Function.identity(),
- (TileConfigModel m) -> m.multiplicity)
- )
+ (TileConfigModel m) -> m.multiplicity
+ ))
;
currentTile = null;
randSrc = new Random();
}
public void copyTile() throws Util.ImageLoadException {
- Util.copyImage(Util.extractImage(currentTile.imageFile));
+ Util.copyImage(
+ Util.extractImage(currentTile.imageFile)
+ .getScaledInstance(-1, IMAGE_COPY_HEIGHT, 0)
+ );
}
public void drawTile() {