Browse Source

Bugfix: icon for extension methods

pull/1/head
Daniel Grunwald 16 years ago
parent
commit
e9b6555bcc
  1. 4
      ILSpy/MethodTreeNode.cs

4
ILSpy/MethodTreeNode.cs

@ -56,8 +56,8 @@ namespace ICSharpCode.ILSpy
get { get {
if (method.IsSpecialName && method.Name.StartsWith("op_", StringComparison.Ordinal)) if (method.IsSpecialName && method.Name.StartsWith("op_", StringComparison.Ordinal))
return Images.Operator; return Images.Operator;
if (method.IsStatic && method.HasParameters && method.Parameters[0].HasCustomAttributes) { if (method.IsStatic && method.HasCustomAttributes) {
foreach (var ca in method.Parameters[0].CustomAttributes) { foreach (var ca in method.CustomAttributes) {
if (ca.AttributeType.FullName == "System.Runtime.CompilerServices.ExtensionAttribute") if (ca.AttributeType.FullName == "System.Runtime.CompilerServices.ExtensionAttribute")
return Images.ExtensionMethod; return Images.ExtensionMethod;
} }

Loading…
Cancel
Save