Fix bug #23711 about selecting last map generator used in editor

This commit is contained in:
Ryckes 2015-07-26 09:07:47 +02:00
parent d9b5498561
commit da37c16ba7
3 changed files with 12 additions and 0 deletions

View file

@ -29,6 +29,8 @@ Version 1.13.1+dev:
* Added a version dialog button to the title screen, replacing the Paths
option previously found in Preferences -> General.
* Miscellaneous and bug fixes:
* Fixed Generate Map dialog bug that caused last choice of map
generator to not be actually selected (bug #23711).
* Fixed unbound memory read in internal time formatting code with
specially-crafted input.
* Child wesnothd processes spawned by the Host Network Game option on

View file

@ -1176,6 +1176,9 @@
[entry]
name = "Karol Kozub (automagic)"
[/entry]
[entry]
name = "Kevin Montalva (Ryckes)"
[/entry]
[entry]
name = "Kristoffer Grönlund (kegie)"
[/entry]

View file

@ -127,6 +127,13 @@ void teditor_generate_map::pre_show(CVideo& /*video*/, twindow& window)
}
}
if (last_map_generator_ != NULL) {
// We need to call this manually because it won't be called by
// list.select_row() even if we set the callback before
// calling it
this->do_generator_selected(window);
}
list.set_callback_item_change(
boost::bind(&teditor_generate_map::do_generator_selected, this, boost::ref(window)));