Skip to content

Commit

Permalink
select quit button when going up from HoIAF scoreboard
Browse files Browse the repository at this point in the history
  • Loading branch information
BenLubar committed Oct 8, 2023
1 parent 189002a commit 4f7c520
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
#include "cbase.h"
#include "rd_vgui_main_menu_hoiaf_leaderboard_entry.h"
#include "rd_vgui_main_menu_top_bar.h"
#include <vgui/ILocalize.h>
#include <vgui/ISurface.h>
#include "c_asw_steamstats.h"
Expand Down Expand Up @@ -126,3 +127,15 @@ void CRD_VGUI_Main_Menu_HoIAF_Leaderboard_Entry_Large::ApplySettings( KeyValues
SetFont( m_hTextFont );
}
}

vgui::Panel *CRD_VGUI_Main_Menu_HoIAF_Leaderboard_Entry_Large::NavigateUp()
{
vgui::Panel *target = BaseClass::NavigateUp();
if ( CRD_VGUI_Main_Menu_Top_Bar *pTopBar = dynamic_cast< CRD_VGUI_Main_Menu_Top_Bar * >( target ) )
{
// since we're on the right side of the screen, navigate to the right side of the top bar.
pTopBar->NavigateToChild( pTopBar->m_pBtnQuit );
}

return target;
}
Original file line number Diff line number Diff line change
Expand Up @@ -40,5 +40,6 @@ class CRD_VGUI_Main_Menu_HoIAF_Leaderboard_Entry_Large : public CRD_VGUI_Main_Me
~CRD_VGUI_Main_Menu_HoIAF_Leaderboard_Entry_Large();

void ApplySettings( KeyValues *pSettings ) override;
vgui::Panel *NavigateUp() override;
};
}

0 comments on commit 4f7c520

Please sign in to comment.