mirror of
https://github.com/wesnoth/wesnoth
synced 2025-05-18 20:19:32 +00:00
MP Create Game: removed unnecessary mod-selected callback
That function used to handle displaying the mod info in the description field. However, as of e25aa4ac2ce03 the descriptions are shown as tooltips, rendering this function useless. on_mod_toggle calls set_current_mod_index too, so that part wasn't needed either.
This commit is contained in:
parent
5a05d7e849
commit
86f026281b
@ -250,13 +250,9 @@ void mp_create_game::pre_show(window& win)
|
||||
connect_signal_notify_modified(mog_toggle, std::bind(&mp_create_game::on_mod_toggle, this, i));
|
||||
}
|
||||
|
||||
connect_signal_notify_modified(mod_list, std::bind(&mp_create_game::on_mod_select, this, std::ref(win)));
|
||||
|
||||
// No mods, hide the header
|
||||
if(mod_list.get_item_count() <= 0) {
|
||||
find_widget<styled_widget>(&win, "mods_header", false).set_visible(widget::visibility::invisible);
|
||||
} else {
|
||||
on_mod_select(win);
|
||||
}
|
||||
|
||||
//
|
||||
@ -479,11 +475,6 @@ void mp_create_game::on_tab_select(window& window)
|
||||
}
|
||||
}
|
||||
|
||||
void mp_create_game::on_mod_select(window& window)
|
||||
{
|
||||
create_engine_.set_current_mod_index(find_widget<listbox>(&window, "mod_list", false).get_selected_row());
|
||||
}
|
||||
|
||||
void mp_create_game::on_mod_toggle(const int index)
|
||||
{
|
||||
create_engine_.set_current_mod_index(index);
|
||||
|
@ -113,7 +113,6 @@ private:
|
||||
|
||||
void on_game_select(window& window);
|
||||
void on_tab_select(window& window);
|
||||
void on_mod_select(window& window);
|
||||
void on_era_select(window& window);
|
||||
void on_mod_toggle(const int index);
|
||||
void on_random_faction_mode_select(window& window);
|
||||
|
Loading…
x
Reference in New Issue
Block a user