The GUI1 textbox widget had a mechanism to reject input until it has
received an SDL_KEYDOWN event, but it didn't do any good. I suspect this
regressed in commit 61ccf2fc, which changed the type of the event handler
container from std::vector to std::list. Apparently, starting from that
commit, an event (say, an SDL_KEYDOWN event) will also be delivered to
any event listeners which are registered by existing event handlers.
In other words:
1. the player presses ;
2. SDL generates an SDL_KEYDOWN event
3. a handler for that event creates the command console
4. the command console registers a handler for SDL events
5. the original keypress event is delivered to the command console
6. the console starts listening for input as a result of that event
7. SDL generates an SDL_TEXTINPUT event, still for the same keypress
8. the console inserts the ; character
I made the textbox loop through all the keys in construction, and store a
set of all pressed keys. The box will ignore all input until all the keys
which were down at the time it was created have been released. The fix
stops the stray ; character from appearing.
Commit 18d7736 caused an infinite loop.
In HttT S14 we have a sighted event which includes [teleport] tags. This commit causes the sighted event to run to completion, then re-fire, in an infinite loop. Removing the [teleport] tags stopped the loop. Reversing this commit does, as well.
And move its code in other files where it fits better.
This also moves some code from actions.cpp to the new file
advancements.cpp
This also removed a parameter from show_objectives and
menu_handler::objectives that was always gui_->viewing_side()
Previously, if a side wasn't know and you weren't in debug mode, the 'Unknown' rows
weren't being added to the list. In addition, continuing to the next team meant the
scenario settings list didn't get filled in with the unknown sides either.