Casting an rvalue to nonconst reference is illegal. I'm not positive why these are considered to be rvalues when they are cast.

This commit is contained in:
Steve Checkoway
2006-10-11 09:33:09 +00:00
parent 1c372a918c
commit c532646ac1
4 changed files with 12 additions and 4 deletions
+5 -1
View File
@@ -406,7 +406,11 @@ void ScreenTextEntryVisual::MoveY( int iDir )
do
{
m_iFocusY = enum_add2( m_iFocusY, +iDir );
wrap( (int&)m_iFocusY, NUM_KeyboardRow );
{
int temp = m_iFocusY;
wrap( temp, NUM_KeyboardRow );
m_iFocusY = KeyboardRow( temp );
}
// HACK: Round to nearest option so that we always stop
// on KEYBOARD_ROW_SPECIAL.