[Mono-bugs] [Bug 80292][Min] New - the MemberDescriptor.DisplayName property should take in account the DisplayNameAttribute
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Sun Dec 17 18:54:06 EST 2006
Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.
Changed by catanzariti at yahoo.com.
http://bugzilla.ximian.com/show_bug.cgi?id=80292
--- shadow/80292 2006-12-17 18:54:06.000000000 -0500
+++ shadow/80292.tmp.24722 2006-12-17 18:54:06.000000000 -0500
@@ -0,0 +1,43 @@
+Bug#: 80292
+Product: Mono: Class Libraries
+Version: 1.2
+OS:
+OS Details: Ubuntu 6.10
+Status: NEW
+Resolution:
+Severity:
+Priority: Minor
+Component: System
+AssignedTo: mono-bugs at ximian.com
+ReportedBy: catanzariti at yahoo.com
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: the MemberDescriptor.DisplayName property should take in account the DisplayNameAttribute
+
+namespace : System.ComponentModel
+class : MemberDescriptor
+property : DisplayName
+
+At the present time, the DisplayName property implementation is exactly the
+same as the Name property implementation. Actually, it should take in
+account the DisplayNameAttribute if assigned to the property.
+
+This is an implementation proposal :
+
+public abstract class MemberDescriptor
+{
+ public virtual string DisplayName
+ {
+ get
+ {
+ foreach (Attribute attr in AttributeArray)
+ {
+ if (attr is DisplayNameAttribute)
+ return ((DisplayNameAttribute) attr).DisplayName;
+ }
+ return name;
+ }
+ }
+}
More information about the mono-bugs
mailing list