mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-29 08:34:37 +01:00
move constant
This commit is contained in:
parent
ad2c725a58
commit
3da04d092d
3 changed files with 6 additions and 5 deletions
|
@ -56,8 +56,6 @@ public class BoardActivity extends Activity implements UtilCtxt {
|
|||
private static final int QUERY_ENDGAME = Utils.DIALOG_LAST + 5;
|
||||
private static final int ASK_PASSWORD_BLK = Utils.DIALOG_LAST + 6;
|
||||
|
||||
private static final int ZOOM_AMT = 2;
|
||||
|
||||
private BoardView m_view;
|
||||
private int m_jniGamePtr;
|
||||
private CurGameInfo m_gi;
|
||||
|
@ -319,10 +317,10 @@ public class BoardActivity extends Activity implements UtilCtxt {
|
|||
} else {
|
||||
switch( keyCode ) {
|
||||
case KeyEvent.KEYCODE_VOLUME_DOWN:
|
||||
handled = doZoom( -ZOOM_AMT );
|
||||
handled = doZoom( -JNIThread.ZOOM_AMT );
|
||||
break;
|
||||
case KeyEvent.KEYCODE_VOLUME_UP:
|
||||
handled = doZoom( ZOOM_AMT );
|
||||
handled = doZoom( JNIThread.ZOOM_AMT );
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -212,7 +212,8 @@ public class BoardView extends View implements DrawCtx, BoardHandler,
|
|||
public void onZoom( boolean zoomIn )
|
||||
{
|
||||
if ( null != m_jniThread ) {
|
||||
int zoomBy = zoomIn ? 2 : -2;
|
||||
int zoomBy = zoomIn ? JNIThread.ZOOM_AMT
|
||||
: -JNIThread.ZOOM_AMT;
|
||||
m_jniThread.handle( JNIThread.JNICmd.CMD_ZOOM, zoomBy );
|
||||
}
|
||||
}
|
||||
|
|
|
@ -74,6 +74,8 @@ public class JNIThread extends Thread {
|
|||
public static final int DIALOG = 3;
|
||||
public static final int QUERY_ENDGAME = 4;
|
||||
|
||||
public static final int ZOOM_AMT = 2;
|
||||
|
||||
private boolean m_stopped = false;
|
||||
private int m_jniGamePtr;
|
||||
private CurGameInfo m_gi;
|
||||
|
|
Loading…
Add table
Reference in a new issue