You don't know that enumerations and integers are the same size; don't assume so. (Fixes assert failure on entering appearance options)

This commit is contained in:
Ben Anderson
2005-05-04 23:43:22 +00:00
parent b7d2e64dbd
commit abbfc6ad7b
+8 -1
View File
@@ -266,7 +266,14 @@ static void DefaultNoteSkin( int &sel, bool ToSel, const ConfOption *pConfOption
MOVE( Instructions, PREFSMAN->m_bShowInstructions );
MOVE( OniScoreDisplay, PREFSMAN->m_bDancePointsForOni );
MOVE( SongGroup, PREFSMAN->m_bShowSelectGroup );
MOVE( WheelSections, (int &) PREFSMAN->m_MusicWheelUsesSections );
static void WheelSections( int &sel, bool ToSel, const ConfOption *pConfOption )
{
// XXX: NEVER, ALWAYS, etc. seem kinda ambiguous...
const PrefsManager::MusicWheelUsesSections mapping[] = { PrefsManager::NEVER, PrefsManager::ALWAYS, PrefsManager::ABC_ONLY };
MoveMap( sel, PREFSMAN->m_MusicWheelUsesSections, ToSel, mapping, ARRAYSIZE(mapping) );
}
MOVE( CourseSort, (int &) PREFSMAN->m_iCourseSortOrder );
MOVE( RandomAtEnd, PREFSMAN->m_bMoveRandomToEnd );
MOVE( Translations, PREFSMAN->m_bShowNativeLanguage );