mirror of
git://xwords.git.sourceforge.net/gitroot/xwords/xwords
synced 2025-01-18 22:26:30 +01:00
add dictNames() variant that takes a GameLock
This commit is contained in:
parent
61334efa1a
commit
218d232798
1 changed files with 17 additions and 5 deletions
|
@ -596,6 +596,23 @@ public class GameUtils {
|
|||
int[] missingLang )
|
||||
{
|
||||
byte[] stream = savedGame( context, rowid );
|
||||
return dictNames( context, stream, missingLang );
|
||||
}
|
||||
|
||||
public static String[] dictNames( Context context, long rowid )
|
||||
{
|
||||
return dictNames( context, rowid, null );
|
||||
}
|
||||
|
||||
public static String[] dictNames( Context context, GameLock lock )
|
||||
{
|
||||
byte[] stream = savedGame( context, lock );
|
||||
return dictNames( context, stream, null );
|
||||
}
|
||||
|
||||
private static String[] dictNames( Context context, byte[] stream,
|
||||
int[] missingLang )
|
||||
{
|
||||
CurGameInfo gi = new CurGameInfo( context );
|
||||
XwJNI.gi_from_stream( gi, stream );
|
||||
if ( null != missingLang ) {
|
||||
|
@ -604,11 +621,6 @@ public class GameUtils {
|
|||
return gi.dictNames();
|
||||
}
|
||||
|
||||
public static String[] dictNames( Context context, long rowid )
|
||||
{
|
||||
return dictNames( context, rowid, null );
|
||||
}
|
||||
|
||||
public static boolean gameDictsHere( Context context, long rowid )
|
||||
{
|
||||
return gameDictsHere( context, rowid, null, null );
|
||||
|
|
Loading…
Reference in a new issue