if the wheel is locked, don't allow Ctrl+Letter to sort

This commit is contained in:
AJ Kelly
2010-01-13 00:43:21 +00:00
parent bc331f3fc6
commit 8ceb0a6967
+15 -11
View File
@@ -359,22 +359,26 @@ void ScreenSelectMusic::Input( const InputEventPlus &input )
if ( bHoldingCtrl && ( c >= 'A' ) && ( c <= 'Z' ) )
{
SortOrder so = GAMESTATE->m_SortOrder;
if ( ( so != SORT_TITLE ) && ( so != SORT_ARTIST ) )
// Don't change sort order when the wheel is locked.
if( !m_MusicWheel.WheelIsLocked() )
{
so = SORT_TITLE;
SortOrder so = GAMESTATE->m_SortOrder;
if ( ( so != SORT_TITLE ) && ( so != SORT_ARTIST ) )
{
so = SORT_TITLE;
GAMESTATE->m_PreferredSortOrder = so;
GAMESTATE->m_SortOrder.Set( so );
// Odd, changing the sort order requires us to call SetOpenSection more than once
GAMESTATE->m_PreferredSortOrder = so;
GAMESTATE->m_SortOrder.Set( so );
// Odd, changing the sort order requires us to call SetOpenSection more than once
m_MusicWheel.ChangeSort( so );
m_MusicWheel.SetOpenSection( ssprintf("%c", c ) );
}
m_MusicWheel.SelectSection( ssprintf("%c", c ) );
m_MusicWheel.ChangeSort( so );
m_MusicWheel.SetOpenSection( ssprintf("%c", c ) );
AfterMusicChange();
return;
}
m_MusicWheel.SelectSection( ssprintf("%c", c ) );
m_MusicWheel.ChangeSort( so );
m_MusicWheel.SetOpenSection( ssprintf("%c", c ) );
AfterMusicChange();
return;
}
// debugging?