diff --git a/src/states_screens/arenas_screen.cpp b/src/states_screens/arenas_screen.cpp index 273c5cf7d..838d2a60c 100644 --- a/src/states_screens/arenas_screen.cpp +++ b/src/states_screens/arenas_screen.cpp @@ -56,12 +56,27 @@ void ArenasScreen::loadedFromFile() //FIXME: this returns groups for arenas but tracks too. this means that some of them // may contain only tracks, no arenas, and thus add an empty tab here... const std::vector& groups = track_manager->getAllGroups(); - const int group_amount = groups.size(); + + // add standard group first for (int n=0; naddTextChild( stringw(groups[n].c_str()).c_str(), groups[n]); + if (groups[n] == DEFAULT_GROUP_NAME) + { + //FIXME: group name not translated + tabs->addTextChild( stringw(groups[n].c_str()).c_str(), groups[n]); + break; + } + } + + // add others after + for (int n=0; naddTextChild( stringw(groups[n].c_str()).c_str(), groups[n]); + } } if (group_amount > 1) diff --git a/src/states_screens/kart_selection.cpp b/src/states_screens/kart_selection.cpp index b524fed1c..863360e04 100644 --- a/src/states_screens/kart_selection.cpp +++ b/src/states_screens/kart_selection.cpp @@ -726,13 +726,27 @@ void KartSelectionScreen::loadedFromFile() tabs->clearAllChildren(); const std::vector& groups = kart_properties_manager->getAllGroups(); - const int group_amount = groups.size(); + // add default group first for (int n=0; naddTextChild( stringw(groups[n].c_str()).c_str() , groups[n]); + if (groups[n] == DEFAULT_GROUP_NAME) + { + //FIXME: group name not translated + tabs->addTextChild( stringw(groups[n].c_str()).c_str() , groups[n]); + break; + } + } + + // add others after + for (int n=0; naddTextChild( stringw(groups[n].c_str()).c_str() , groups[n]); + } } if (group_amount > 1) diff --git a/src/states_screens/tracks_screen.cpp b/src/states_screens/tracks_screen.cpp index b95586411..ceb13afa9 100644 --- a/src/states_screens/tracks_screen.cpp +++ b/src/states_screens/tracks_screen.cpp @@ -56,12 +56,27 @@ void TracksScreen::loadedFromFile() tabs->clearAllChildren(); const std::vector& groups = track_manager->getAllGroups(); - const int group_amount = groups.size(); + + // add standard group first for (int n=0; naddTextChild( stringw(groups[n].c_str()).c_str(), groups[n] ); + if (groups[n] == DEFAULT_GROUP_NAME) + { + // FIXME: group name is not translated + tabs->addTextChild( stringw(groups[n].c_str()).c_str(), groups[n] ); + break; + } + } + + // add others after + for (int n=0; naddTextChild( stringw(groups[n].c_str()).c_str(), groups[n] ); + } } if (group_amount > 1)