void BattleListTab::UpdateBattle( IBattle& battle ) { if ( !battle.GetGUIListActiv() ) { AddBattle( battle ); return; } if ( m_filter->GetActiv() && !m_filter->FilterBattle( battle ) ) { RemoveBattle( battle ); return; } m_battle_list->UpdateBattle( battle ); if ( &battle == m_sel_battle ) SelectBattle( m_sel_battle ); }
void BattleListTab::UpdateBattle(IBattle& battle) { if (!battle.GetGUIListActiv()) { AddBattle(battle); } if (m_filter->GetActiv() && !m_filter->FilterBattle(battle)) { RemoveBattle(battle); if (&battle == m_sel_battle) { m_sel_battle = NULL; SelectBattle(NULL); m_battle_list->SetSelectedIndex(-1); } return; } m_battle_list->UpdateBattle(battle); if (&battle == m_sel_battle) SelectBattle(m_sel_battle); }