don't show game name if it's hidden in BoardActivity -- that is, use

the same preference to govern both.  Still to do: need to inval all
game list items when that preference changes.
This commit is contained in:
Andy2 2011-03-04 07:40:56 -08:00
parent 2fdda2bae1
commit 1b6d8ebed2

View file

@ -73,6 +73,7 @@ public class GameListAdapter extends XWListAdapter {
if ( null == layout ) {
layout = m_factory.inflate( m_layoutId, null );
boolean hideTitle = CommonPrefs.getHideTitleBar( m_context );
// If we can't read the summary right now we still need to
// return a view but shouldn't cache it
@ -95,7 +96,11 @@ public class GameListAdapter extends XWListAdapter {
}
view = (TextView)layout.findViewById( R.id.game_name );
if ( hideTitle ) {
view.setVisibility( View.GONE );
} else {
view.setText( GameUtils.gameName( m_context, path ) );
}
view = (TextView)layout.findViewById( R.id.state );
view.setText( summary.summarizeState( m_context ) );
view = (TextView)layout.findViewById( R.id.dict );