hard-code tiles drawn nearly-square, just to see what it looks like.

Making them exactly square would probably take a new jni call.  And if
I ship this it needs to be optional, controlled by a preference.
This commit is contained in:
Eric House 2012-12-05 19:15:20 -08:00
parent e719c6e61d
commit 93bf2a1b3e

View file

@ -53,6 +53,8 @@ public class BoardView extends View implements DrawCtx, BoardHandler,
private static final int PINCH_THRESHOLD = 40;
private static final int SCORE_HT_DROP = 2;
private static final boolean DEBUG_DRAWFRAMES = false;
// this can be a preference
private static final boolean MAKETILESSQUARE = true;
private Context m_context;
private Paint m_drawPaint;
@ -379,8 +381,12 @@ public class BoardView extends View implements DrawCtx, BoardHandler,
heightLeft = cellSize * 3 / 2;
}
heightLeft /= 3;
trayHt += heightLeft * 2;
scoreHt += heightLeft;
trayHt += heightLeft * 2;
if ( MAKETILESSQUARE && trayHt > width / 7 ) {
trayHt = width / 7;
}
heightUsed = trayHt + scoreHt + ((nCells - nToScroll) * cellSize);
}