mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-20 22:26:54 +01:00
cleanup: use new board_drawSnapshot on existing game
This commit is contained in:
parent
bf7a38da08
commit
b9bb1e2684
2 changed files with 3 additions and 16 deletions
|
@ -351,21 +351,6 @@ public class GameUtils {
|
|||
return thumb;
|
||||
}
|
||||
|
||||
public static Bitmap loadMakeBitmap( Context context, byte[] stream,
|
||||
GameLock lock )
|
||||
{
|
||||
Bitmap thumb = null;
|
||||
CurGameInfo gi = new CurGameInfo( context );
|
||||
GamePtr gamePtr = loadMakeGame( context, gi, null, null, stream,
|
||||
lock.getRowid() );
|
||||
if ( null != gamePtr ) {
|
||||
thumb = takeSnapshot( context, gamePtr, gi );
|
||||
gamePtr.release();
|
||||
DBUtils.saveThumbnail( context, lock, thumb );
|
||||
}
|
||||
return thumb;
|
||||
}
|
||||
|
||||
public static Bitmap takeSnapshot( Context context, GamePtr gamePtr,
|
||||
CurGameInfo gi )
|
||||
{
|
||||
|
|
|
@ -375,7 +375,9 @@ public class JNIThread extends Thread {
|
|||
XwJNI.game_saveSucceeded( m_jniGamePtr );
|
||||
m_lastSavedState = newHash;
|
||||
|
||||
GameUtils.loadMakeBitmap( m_context, state, m_lock );
|
||||
Bitmap thumb
|
||||
= GameUtils.takeSnapshot( m_context, m_jniGamePtr, m_gi );
|
||||
DBUtils.saveThumbnail( m_context, m_lock, thumb );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue