Removed unused function mp::ui::set_selected_game.

This commit is contained in:
Guillaume Melquiond 2009-12-06 09:56:49 +00:00
parent 24d78af915
commit 6ae566de75
2 changed files with 0 additions and 21 deletions

View File

@ -292,7 +292,6 @@ ui::ui(game_display& disp, const std::string& title, const config& cfg, chat& c,
users_menu_(disp.video(), std::vector<std::string>(), false, -1, -1, NULL, &umenu_style),
user_list_(),
selected_game_(""),
selected_user_(""),
selected_user_changed_(false),
@ -721,9 +720,6 @@ void ui::gamelist_updated(bool silent)
u_elem.registered = utils::string_bool(user["registered"]);
u_elem.game_id = user["game_id"];
u_elem.location = user["location"];
if (!u_elem.game_id.empty() && u_elem.game_id == selected_game_) {
u_elem.state = SEL_GAME;
}
if (u_elem.name == preferences::login()) {
u_elem.relation = ME;
} else if (preferences::is_ignored(u_elem.name)) {
@ -784,15 +780,6 @@ void ui::gamelist_updated(bool silent)
set_user_menu_items(menu_strings);
}
void ui::set_selected_game(const std::string& game_id)
{
// reposition the player list to show the players in the selected game
if (preferences::sort_list() && (selected_game_ != game_id)) {
users_menu_.move_selection(0);
}
selected_game_ = game_id;
}
void ui::set_user_menu_items(const std::vector<std::string>& list)
{
users_menu_.set_items(list,true,true);

View File

@ -174,12 +174,6 @@ protected:
/** Sets the result of this dialog, to be checked by get_result(). */
result set_result(result res);
/**
* Sets the name of the selected game which is used to highlight the names
* of the players which have joined this game.
*/
void set_selected_game(const std::string& game_name);
/**
* Called each time the gamelist_ variable is updated. May be
* overridden by child classes to add custom gamelist behaviour.
@ -233,8 +227,6 @@ private:
std::vector<std::string> user_list_;
std::string selected_game_;
std::string selected_user_;
bool selected_user_changed_;