1818using System . Windows . Input ;
1919using MS . Utility ;
2020
21- using SR = MS . Internal . PresentationCore . SR ;
21+ using SR = MS . Internal . PresentationCore . SR ;
2222
2323namespace System . Windows . Input
2424{
@@ -28,11 +28,11 @@ namespace System.Windows.Input
2828 public class MouseActionConverter : TypeConverter
2929 {
3030 ///<summary>
31- /// CanConvertFrom - Used to check whether we can convert a string into a MouseAction
31+ /// Used to check whether we can convert a <see langword=" string"/> into a <see cref=" MouseAction"/>.
3232 ///</summary>
3333 ///<param name="context">ITypeDescriptorContext</param>
3434 ///<param name="sourceType">type to convert from</param>
35- ///<returns>true if the given type can be converted, false otherwise</returns>
35+ ///<returns><see langword=" true"/> if the given <paramref name="sourceType"/> can be converted from, <see langword=" false"/> otherwise. </returns>
3636 public override bool CanConvertFrom ( ITypeDescriptorContext context , Type sourceType )
3737 {
3838 // We can only handle string.
@@ -46,13 +46,12 @@ public override bool CanConvertFrom(ITypeDescriptorContext context, Type sourceT
4646 }
4747 }
4848
49-
50- ///<summary>
51- ///TypeConverter method override.
52- ///</summary>
53- ///<param name="context">ITypeDescriptorContext</param>
54- ///<param name="destinationType">Type to convert to</param>
55- ///<returns>true if conversion is possible</returns>
49+ /// <summary>
50+ /// Used to check whether we can convert specified value to <see langword="string"/>.
51+ /// </summary>
52+ /// <param name="context">ITypeDescriptorContext</param>
53+ /// <param name="destinationType">Type to convert to</param>
54+ /// <returns><see langword="true"/> if conversion to <see langword="string"/> is possible, <see langword="false"/> otherwise.</returns>
5655 public override bool CanConvertTo ( ITypeDescriptorContext context , Type destinationType )
5756 {
5857 // We can convert to an InstanceDescriptor or to a string.
@@ -61,19 +60,19 @@ public override bool CanConvertTo(ITypeDescriptorContext context, Type destinati
6160 // When invoked by the serialization engine we can convert to string only for known type
6261 if ( context != null && context . Instance != null )
6362 {
64- return ( MouseActionConverter . IsDefinedMouseAction ( ( MouseAction ) context . Instance ) ) ;
65- }
63+ return IsDefinedMouseAction ( ( MouseAction ) context . Instance ) ;
64+ }
6665 }
6766 return false ;
6867 }
6968
7069 /// <summary>
71- /// ConvertFrom()
70+ /// Converts <paramref name="source"/> of <see langword="string"/> type to its <see cref="MouseAction"/> represensation.
7271 /// </summary>
7372 /// <param name="context">Parser Context</param>
7473 /// <param name="culture">Culture Info</param>
7574 /// <param name="source">MouseAction String</param>
76- /// <returns></returns>
75+ /// <returns>A <see cref="MouseAction"/> representing the <see langword="string"/> specified by <paramref name="source"/>. </returns>
7776 public override object ConvertFrom ( ITypeDescriptorContext context , CultureInfo culture , object source )
7877 {
7978 if ( source is not string mouseAction )
@@ -92,17 +91,17 @@ _ when mouseActionToken.Equals("LeftDoubleClick", StringComparison.OrdinalIgnore
9291 _ when mouseActionToken . Equals ( "RightDoubleClick" , StringComparison . OrdinalIgnoreCase ) => MouseAction . RightDoubleClick ,
9392 _ when mouseActionToken . Equals ( "MiddleDoubleClick" , StringComparison . OrdinalIgnoreCase ) => MouseAction . MiddleDoubleClick ,
9493 _ => throw new NotSupportedException ( SR . Format ( SR . Unsupported_MouseAction , mouseActionToken . ToString ( ) ) )
95- } ;
94+ } ;
9695 }
9796
9897 /// <summary>
99- /// ConvertTo()
98+ /// Converts a <paramref name="value"/> of <see cref="MouseAction"/> to its <see langword="string"/> represensation.
10099 /// </summary>
101100 /// <param name="context">Serialization Context</param>
102101 /// <param name="culture">Culture Info</param>
103102 /// <param name="value">MouseAction value </param>
104103 /// <param name="destinationType">Type to Convert</param>
105- /// <returns>string if parameter is a MouseAction</returns>
104+ /// <returns>A <see langword="string"/> representing the <see cref=" MouseAction"/> specified by <paramref name="value"/>. </returns>
106105 public override object ConvertTo ( ITypeDescriptorContext context , CultureInfo culture , object value , Type destinationType )
107106 {
108107 ArgumentNullException . ThrowIfNull ( destinationType ) ;
0 commit comments