Fix bug #24762: Avoid modifying the event handlers at the wrong time
This resurrects the old check that was used to determine when it was safe to create the buttons. It avoids it happening as a result of an actual draw-all event, instead only happening when the GUI is being updated.
This commit is contained in:
parent
6347c646e2
commit
8c94170c46
1 changed files with 3 additions and 2 deletions
|
@ -2668,8 +2668,9 @@ void display::redraw_everything()
|
|||
|
||||
theme_.set_resolution(screen_area());
|
||||
|
||||
create_buttons();
|
||||
render_buttons();
|
||||
if(!menu_buttons_.empty() || !action_buttons_.empty() || !sliders_.empty() ) {
|
||||
create_buttons();
|
||||
}
|
||||
|
||||
panelsDrawn_ = false;
|
||||
if (!gui::in_dialog()) {
|
||||
|
|
Loading…
Add table
Reference in a new issue