diff options
-rw-r--r-- | win/C#/Parsing/Title.cs | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/win/C#/Parsing/Title.cs b/win/C#/Parsing/Title.cs index 1a98a58ed..a88b7bab7 100644 --- a/win/C#/Parsing/Title.cs +++ b/win/C#/Parsing/Title.cs @@ -149,19 +149,15 @@ namespace Handbrake.Parsing if (!Properties.Settings.Default.noDvdNav)
{
// Get the Angles for the title.
- m = Regex.Match(output.ReadLine(), @" \+ angle\(s\) ([0-9,])");
+ m = Regex.Match(output.ReadLine(), @" \+ angle\(s\) ([0-9])");
if (m.Success)
{
String angleList = m.Value.Replace("+ angle(s) ", "").Trim();
+ int angleCount;
+ int.TryParse(angleList, out angleCount);
- if (angleList.Contains(","))
- {
- string[] angles = angleList.Split(',');
- foreach (string s in angles)
- thisTitle.m_angles.Add(s);
- }
- else
- thisTitle.m_angles.Add(m.Value.Replace("+ angle(s) ", "").Trim());
+ for (int i = 1; i <= angleCount; i++)
+ thisTitle.m_angles.Add(i.ToString());
}
}
|