small bugfix
This commit is contained in:
parent
1be773a20f
commit
8c51049821
@ -100,11 +100,11 @@ class EventParser(FileParser):
|
|||||||
# Now try to look for event definitions. Moving windows allows multi line event definitions
|
# Now try to look for event definitions. Moving windows allows multi line event definitions
|
||||||
# These two variants need to be checked
|
# These two variants need to be checked
|
||||||
event_match = re.match(
|
event_match = re.match(
|
||||||
r"[\s]*static const(?:expr)?[\s]*Event[\s]*([\w]*)[\s]*=",
|
r"[\s]*static const(?:expr)?[\s]*Event[\s]*([\w]*)[\s]*=([^\n]*)",
|
||||||
moving_window[self.moving_window_center_idx],
|
moving_window[self.moving_window_center_idx],
|
||||||
)
|
)
|
||||||
macro_api_match = False
|
macro_api_match = False
|
||||||
for idx in range(0, 3):
|
for idx in range(3):
|
||||||
if "MAKE_EVENT" in moving_window[self.moving_window_center_idx + idx]:
|
if "MAKE_EVENT" in moving_window[self.moving_window_center_idx + idx]:
|
||||||
macro_api_match = True
|
macro_api_match = True
|
||||||
break
|
break
|
||||||
@ -285,7 +285,7 @@ def write_translation_source_file(
|
|||||||
definitions = ""
|
definitions = ""
|
||||||
|
|
||||||
function = (
|
function = (
|
||||||
"const char * translateEvents(Event event) {\n switch( (event & 0xffff) ) {\n"
|
"const char* translateEvents(Event event) {\n switch( (event & 0xFFFF) ) {\n"
|
||||||
)
|
)
|
||||||
for entry in event_list:
|
for entry in event_list:
|
||||||
event_id = entry[0]
|
event_id = entry[0]
|
||||||
|
Loading…
x
Reference in New Issue
Block a user