turn off saving logs for now; move capture of title to where it's more

likely to succeed, and assert that it is. I think this will fix the
title-not-reverting problem I've been seeing.
This commit is contained in:
Eric House 2016-05-10 06:40:23 -07:00
parent 608533d189
commit 253c0d7496
2 changed files with 20 additions and 17 deletions

View file

@ -67,8 +67,8 @@ public class DBUtils {
public static final int GROUPID_UNSPEC = -1;
public static final String KEY_NEWGAMECOUNT = "DBUtils.newGameCount";
// how many log rows to keep?
private static final int LOGLIMIT = 5000;
// how many log rows to keep? (0 means off)
private static final int LOGLIMIT = 0;
private static final String DICTS_SEP = ",";
@ -2418,6 +2418,7 @@ public class DBUtils {
private static void appendLog( Context context, String msg )
{
if ( 0 < LOGLIMIT ) {
ContentValues values = new ContentValues();
values.put( DBHelper.MESSAGE, msg );
@ -2436,6 +2437,7 @@ public class DBUtils {
db.close();
}
}
}
private static void copyGameDB( Context context, boolean toSDCard )
{

View file

@ -918,6 +918,9 @@ public class GamesListDelegate extends ListDelegateBase
@Override
protected void init( Bundle savedInstanceState )
{
m_origTitle = getTitle();
Assert.assertTrue( m_origTitle.equals( getString(R.string.app_name) ) );
m_handler = new Handler();
// Next line useful if contents of DB are crashing app on start
// DBUtils.saveDB( m_activity );
@ -951,8 +954,6 @@ public class GamesListDelegate extends ListDelegateBase
tryStartsFromIntent( getIntent() );
getDictForLangIf();
m_origTitle = getTitle();
} // init
// protected View onCreateView( Bundle savedInstanceState )