hide underlines of hidden rows (for real this time)
This commit is contained in:
@@ -408,15 +408,17 @@ void OptionRow::UpdateEnabledDisabled(
|
|||||||
case LAYOUT_SHOW_ONE_IN_ROW:
|
case LAYOUT_SHOW_ONE_IN_ROW:
|
||||||
FOREACH_HumanPlayer( pn )
|
FOREACH_HumanPlayer( pn )
|
||||||
{
|
{
|
||||||
bool bEnabled = m_RowDef.m_vEnabledForPlayers.find(pn) != m_RowDef.m_vEnabledForPlayers.end();
|
bool bRowEnabled = m_RowDef.m_vEnabledForPlayers.find(pn) != m_RowDef.m_vEnabledForPlayers.end();
|
||||||
|
|
||||||
if( bThisRowHasFocus[pn] )
|
if( bThisRowHasFocus[pn] )
|
||||||
color = colorFocus;
|
color = colorFocus;
|
||||||
else if( bEnabled )
|
else if( bRowEnabled )
|
||||||
color = colorNoFocus;
|
color = colorNoFocus;
|
||||||
else
|
else
|
||||||
color = colorDisabled;
|
color = colorDisabled;
|
||||||
|
|
||||||
|
float fEnabledDisabledAlpha = bRowEnabled ? 1:0;
|
||||||
|
|
||||||
unsigned item_no = m_RowDef.bOneChoiceForAllPlayers ? 0 : pn;
|
unsigned item_no = m_RowDef.bOneChoiceForAllPlayers ? 0 : pn;
|
||||||
|
|
||||||
// If player_no is 2 and there is no player 1:
|
// If player_no is 2 and there is no player 1:
|
||||||
@@ -435,7 +437,7 @@ void OptionRow::UpdateEnabledDisabled(
|
|||||||
OptionsCursor &ul = *m_Underline[p][item_no];
|
OptionsCursor &ul = *m_Underline[p][item_no];
|
||||||
ul.StopTweening();
|
ul.StopTweening();
|
||||||
ul.BeginTweening( fTweenSeconds );
|
ul.BeginTweening( fTweenSeconds );
|
||||||
ul.SetDiffuseAlpha( fDiffuseAlpha );
|
ul.SetDiffuseAlpha( fEnabledDisabledAlpha );
|
||||||
ul.SetY( m_fY );
|
ul.SetY( m_fY );
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user