summaryrefslogtreecommitdiffstats
path: root/win/CS/HandBrakeWPF/Extensions
diff options
context:
space:
mode:
authorsr55 <[email protected]>2018-11-10 14:18:12 +0000
committersr55 <[email protected]>2018-11-10 14:20:09 +0000
commit942f28023d46fab037058a22fcf305a533bb5373 (patch)
treeadea56bec29961ff3728d543d92508849a8808ce /win/CS/HandBrakeWPF/Extensions
parentaa03552c64ac34fbc3a79396a72df3cd37b6a6f2 (diff)
WinGui: Make the Autoname macros case-insensitive. Fixes #1670
Diffstat (limited to 'win/CS/HandBrakeWPF/Extensions')
-rw-r--r--win/CS/HandBrakeWPF/Extensions/StringExtensions.cs9
1 files changed, 6 insertions, 3 deletions
diff --git a/win/CS/HandBrakeWPF/Extensions/StringExtensions.cs b/win/CS/HandBrakeWPF/Extensions/StringExtensions.cs
index cf7e507aa..220d6f14d 100644
--- a/win/CS/HandBrakeWPF/Extensions/StringExtensions.cs
+++ b/win/CS/HandBrakeWPF/Extensions/StringExtensions.cs
@@ -10,10 +10,8 @@
namespace HandBrakeWPF.Extensions
{
using System.Globalization;
+ using System.Text.RegularExpressions;
- /// <summary>
- /// String Extensions
- /// </summary>
public static class StringExtensions
{
/// <summary>
@@ -36,5 +34,10 @@ namespace HandBrakeWPF.Extensions
return 0;
}
+
+ public static string RegexReplace(this string input, string pattern, string repacelement)
+ {
+ return Regex.Replace(input, pattern, repacelement, RegexOptions.IgnoreCase);
+ }
}
}