Bring shadowed variables back from the dark side.

Alright Colby, happy now?
This commit is contained in:
Jason Felds
2011-03-14 02:54:11 -04:00
parent d855d8c7e8
commit e9df4832f6
14 changed files with 62 additions and 64 deletions
+5 -5
View File
@@ -1488,15 +1488,15 @@ void SongManager::UpdatePreferredSort(RString sPreferredSongs, RString sPreferre
if( MOVE_UNLOCKS_TO_BOTTOM_OF_PREFERRED_SORT.GetValue() )
{
// move all unlock songs to a group at the bottom
PreferredSortSection section;
section.sName = "Unlocks";
PreferredSortSection PFSection;
PFSection.sName = "Unlocks";
FOREACH( UnlockEntry, UNLOCKMAN->m_UnlockEntries, ue )
{
if( ue->m_Type == UnlockRewardType_Song )
{
Song *pSong = ue->m_Song.ToSong();
if( pSong )
section.vpSongs.push_back( pSong );
PFSection.vpSongs.push_back( pSong );
}
}
@@ -1505,14 +1505,14 @@ void SongManager::UpdatePreferredSort(RString sPreferredSongs, RString sPreferre
for( int i=v->vpSongs.size()-1; i>=0; i-- )
{
Song *pSong = v->vpSongs[i];
if( find(section.vpSongs.begin(),section.vpSongs.end(),pSong) != section.vpSongs.end() )
if( find(PFSection.vpSongs.begin(),PFSection.vpSongs.end(),pSong) != PFSection.vpSongs.end() )
{
v->vpSongs.erase( v->vpSongs.begin()+i );
}
}
}
m_vPreferredSongSort.push_back( section );
m_vPreferredSongSort.push_back( PFSection );
}
// prune empty groups