コード例 #1
0
 public override string ToString()
 {
     if (TrackDescription != null)
     {
         return(TrackDescription.Name);
     }
     return(FileName == null?SubtitleType.ToString() : FileName);
 }
コード例 #2
0
 /// <summary>Compares this instance with a specified object, based on the object names.
 /// See <see cref="String.CompareTo(object)" /> for more information.</summary>
 /// <param name="obj">The object to compare this class to.</param>
 /// <returns>
 /// <list type="table">
 ///         <listheader><term>Value</term><description>Condition</description></listheader>
 ///		<item><term>Less than zero</term><description>This instance is less than obj.</description></item>
 ///		<item><term>Zero</term><description>This instance is equal to obj.</description></item>
 ///		<item><term>Greater than zero</term><description>This instance is greater than obj, or obj is a
 ///			null reference.</description></item>
 ///	</list>
 ///	</returns>
 public int CompareTo(object obj)
 {
     return(type.ToString().CompareTo((obj as SubtitleTypeInfo).Type.ToString()));
 }