]> granicus.if.org Git - handbrake/commitdiff
WinGui: Treat empty string as null for Subtitle Name. #2275
authorsr55 <sr55.hb@outlook.com>
Fri, 30 Aug 2019 21:11:59 +0000 (22:11 +0100)
committersr55 <sr55.hb@outlook.com>
Fri, 30 Aug 2019 21:12:27 +0000 (22:12 +0100)
win/CS/HandBrake.Interop/Interop/Json/Encode/SubtitleTrack.cs

index 53f2a404de83e4b5095b75da0b2920bae0b25d78..4e0d79857010416f8f3a53598d0063f80fa9fe23 100644 (file)
@@ -14,6 +14,8 @@ namespace HandBrake.Interop.Interop.Json.Encode
     /// </summary>
     public class SubtitleTrack
     {
+        private string name;
+
         /// <summary>
         /// Gets or sets a value indicating whether burn.
         /// </summary>
@@ -44,7 +46,11 @@ namespace HandBrake.Interop.Interop.Json.Encode
         /// </summary>
         public int Track { get; set; }
 
-        public string Name { get; set; }
+        public string Name
+        {
+            get => string.IsNullOrEmpty(this.name) ? null : this.name;
+            set => this.name = value;
+        }
 
         /// <summary>
         /// Gets or sets the srt.