fix pom_merger: now correctly parse page string

supermerill/SuperSlicer#1203
This commit is contained in:
supermerill 2021-05-31 18:19:42 +02:00 committed by remi durand
parent 0449a49665
commit 949ed6a24d

View File

@ -395,7 +395,15 @@ def parse_ui_file(file_path):
while line_idx < len(lines):
items = lines[line_idx].strip().split(":");
if len(items) > 1:
if items[0]=="page" or items[0]=="group" or items[0]=="line":
if items[0]=="page:
current_line = TranslationLine();
current_line.header_comment = "\n#: "+file_path;#+":"+str(line_idx);
current_line.raw_msgid = "msgid \""+items[1]+"\"";
current_line.msgid = items[1];
current_line.raw_msgstr = "msgstr \"\"";
current_line.msgstr = "";
read_data_lines.append(current_line);
if items[0]=="group" or items[0]=="line":
current_line = TranslationLine();
current_line.header_comment = "\n#: "+file_path;#+":"+str(line_idx);
current_line.raw_msgid = "msgid \""+items[-1]+"\"";