From 48cc8d6044c8ee878aa145abdbebd03b630eec09 Mon Sep 17 00:00:00 2001 From: wardje Date: Sun, 18 Mar 2012 18:38:28 +0000 Subject: [PATCH] Correction in highscore showing on Follow The Leader Calling updateHighScores on every click on the reverse checkbox was a bit optimistic, add a check that there are even highscores to show. git-svn-id: svn+ssh://svn.code.sf.net/p/supertuxkart/code/main/trunk@10996 178a84e3-b1eb-0310-8ba1-8eac791a3b58 --- src/states_screens/dialogs/track_info_dialog.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/states_screens/dialogs/track_info_dialog.cpp b/src/states_screens/dialogs/track_info_dialog.cpp index 934559ffb..fb2a10455 100644 --- a/src/states_screens/dialogs/track_info_dialog.cpp +++ b/src/states_screens/dialogs/track_info_dialog.cpp @@ -263,7 +263,10 @@ GUIEngine::EventPropagation TrackInfoDialog::processEvent(const std::string& eve race_manager->setReverseTrack(m_checkbox->getState()); // Makes sure the highscores get swapped when clicking the 'reverse' // checkbox. - updateHighScores(); + if (race_manager->modeHasHighscores()) + { + updateHighScores(); + } } else if (eventSource == "lapcountspinner") {