mirror of
https://github.com/SubtitleEdit/subtitleedit.git
synced 2024-11-26 13:12:39 +01:00
Minor refactoring - thx Ivandrofly :)
This commit is contained in:
parent
199773ec17
commit
5ed0dd3141
@ -66,9 +66,8 @@ namespace Nikse.SubtitleEdit.Logic.SubtitleFormats
|
||||
string text = line.Remove(0, splitter);
|
||||
p = new Paragraph(DecodeTimeCode(line.Substring(0, splitter)), new TimeCode(0,0,0,0), text);
|
||||
subtitle.Paragraphs.Add(p);
|
||||
text = text.Trim().Trim('–').Trim('.').Trim(';').Trim(':').Trim();
|
||||
if (text.StartsWith("0") || text.StartsWith("1") || text.StartsWith("2") || text.StartsWith("3") || text.StartsWith("4") ||
|
||||
text.StartsWith("5") || text.StartsWith("6") || text.StartsWith("7") || text.StartsWith("8") || text.StartsWith("9"))
|
||||
text = text.Trim().Trim('–', '.', ';', ':').Trim();
|
||||
if (text.Length > 0 && "0123456789".Contains(text[0].ToString()))
|
||||
_errorCount++;
|
||||
}
|
||||
else
|
||||
|
Loading…
Reference in New Issue
Block a user