reflect log-storage state in what menus are available

It'd debug-build-only, but I like knowing what's going on.
This commit is contained in:
Eric House 2020-04-24 21:57:32 -07:00
parent 267a24619a
commit 4e1018d7d2
2 changed files with 9 additions and 0 deletions

View file

@ -1616,6 +1616,10 @@ public class GamesListDelegate extends ListDelegateBase
0 < DBUtils.getGamesWithSendsPending( m_activity ).size();
Utils.setItemVisible( menu, R.id.games_menu_resend, enable );
enable = Log.getStoreLogs();
Utils.setItemVisible( menu, R.id.games_menu_enableLogStorage, !enable );
Utils.setItemVisible( menu, R.id.games_menu_disableLogStorage, enable );
Assert.assertTrue( m_menuPrepared );
}
}

View file

@ -80,6 +80,11 @@ public class Log {
sUseDB = enable;
}
public static boolean getStoreLogs()
{
return sUseDB;
}
public static void enable( boolean newVal )
{
sEnabled = newVal;