mirror of
https://github.com/MaSzyna-EU07/maszyna.git
synced 2026-03-22 15:05:03 +01:00
Improve the keymapper
The keymapper, available as one of the options in the starting menu when the EXE is run without a scenery specified, has undergone a few changes: - Key descriptions are now parsed the way Starter does and are displayed in the window. They are also no longer consumed when saving to a file. - Unbound keys are now also displayed as well. Not all of them though; some entries won't exist if they are not specified in the eu07_input-keyboard.ini file. - You can now unbind a key by pressing F10. The Parser has got a new boolean option: `skipComments`, true by default to leave current behavior unchanged. When set to false, comments will be parsed as ordinary tokens.
This commit is contained in:
@@ -202,7 +202,7 @@ std::string cParser::readToken( bool ToLower, const char *Break ) {
|
||||
token += c;
|
||||
if( findQuotes( token ) ) // do glue together words enclosed in quotes
|
||||
continue;
|
||||
if( trimComments( token ) ) // don't glue together words separated with comment
|
||||
if( skipComments && trimComments( token ) ) // don't glue together words separated with comment
|
||||
break;
|
||||
}
|
||||
if( c == '\n' ) {
|
||||
|
||||
Reference in New Issue
Block a user