mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-02-12 08:47:50 +01:00
cleanup
This commit is contained in:
parent
a902bdcbad
commit
550e637440
1 changed files with 4 additions and 2 deletions
|
@ -218,9 +218,11 @@ public class BoardView extends View implements BoardHandler, SyncedDraw {
|
||||||
Paint paint = new Paint();
|
Paint paint = new Paint();
|
||||||
paint.setTextSize( m_mediumFontHt );
|
paint.setTextSize( m_mediumFontHt );
|
||||||
Rect scratch = new Rect();
|
Rect scratch = new Rect();
|
||||||
paint.getTextBounds( "-00:00", 0, 6, scratch );
|
String timerTxt = "-00:00";
|
||||||
|
paint.getTextBounds( timerTxt, 0, timerTxt.length(), scratch );
|
||||||
int timerWidth = scratch.width();
|
int timerWidth = scratch.width();
|
||||||
int fontWidth = Math.min(m_defaultFontHt, timerWidth / 6);
|
int fontWidth =
|
||||||
|
Math.min(m_defaultFontHt, timerWidth / timerTxt.length());
|
||||||
m_jniThread.handle( JNIThread.JNICmd.CMD_LAYOUT, width, height,
|
m_jniThread.handle( JNIThread.JNICmd.CMD_LAYOUT, width, height,
|
||||||
fontWidth, m_defaultFontHt );
|
fontWidth, m_defaultFontHt );
|
||||||
// We'll be back....
|
// We'll be back....
|
||||||
|
|
Loading…
Add table
Reference in a new issue