When games moved, the destination group is opened and the games that

were moved stay selected.
This commit is contained in:
Eric House 2013-10-23 20:45:14 -07:00
parent 8f8911c7d1
commit 788542c874
3 changed files with 5 additions and 5 deletions

View file

@ -234,6 +234,7 @@ public class GameListAdapter implements ExpandableListAdapter {
GameListItem result =
GameListItem.makeForRow( m_context, rowid, m_handler,
groupPosition, m_fieldID, m_cb );
result.setSelected( m_cb.getSelected( result ) );
return result;
}

View file

@ -337,10 +337,6 @@ public class GameListItem extends LinearLayout
s_invalRows.remove( m_rowid );
}
}
if ( m_cb.getSelected( GameListItem.this ) && m_selected ) {
toggleSelected();
}
}
} // class LoadItemTask

View file

@ -301,6 +301,8 @@ public class GamesList extends XWExpandableListActivity
for ( long rowid : m_rowids ) {
DBUtils.moveGame( GamesList.this, rowid, gid );
}
DBUtils.setGroupExpanded( GamesList.this, gid,
true );
onContentChanged();
}
};
@ -631,7 +633,7 @@ public class GamesList extends XWExpandableListActivity
@Override
public void onBackPressed() {
if ( 0 == m_selGames.size() ) {
if ( 0 == m_selGames.size() && 0 == m_selGroupIDs.size() ) {
super.onBackPressed();
} else {
clearSelections();
@ -796,6 +798,7 @@ public class GamesList extends XWExpandableListActivity
// Game menus
case R.id.list_item_move:
keepSels = true;
if ( 1 >= m_adapter.getGroupCount() ) {
showOKOnlyDialog( R.string.no_move_onegroup );
} else {