2002-07-13 Gonzalo Paniagua Javier <gonzalo@ximian.com>
authorGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Sat, 13 Jul 2002 13:39:39 +0000 (13:39 -0000)
committerGonzalo Paniagua Javier <gonzalo.mono@gmail.com>
Sat, 13 Jul 2002 13:39:39 +0000 (13:39 -0000)
* DefaultEventAttribute.cs: new file.

svn path=/trunk/mcs/; revision=5758

mcs/class/System/System.ComponentModel/ChangeLog
mcs/class/System/System.ComponentModel/DefaultEventAttribute.cs [new file with mode: 0644]

index 9b090769658ce2bd78ad1156e0d8079f8eed550e..d0e2f071481613c1b1247f84b1666465c5e4ff34 100644 (file)
@@ -1,3 +1,7 @@
+2002-07-13  Gonzalo Paniagua Javier <gonzalo@ximian.com>
+
+       * DefaultEventAttribute.cs: new file.
+
 2002-07-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
 
        * AttributeCollection.cs: fixlet.
diff --git a/mcs/class/System/System.ComponentModel/DefaultEventAttribute.cs b/mcs/class/System/System.ComponentModel/DefaultEventAttribute.cs
new file mode 100644 (file)
index 0000000..29495b6
--- /dev/null
@@ -0,0 +1,43 @@
+//
+// System.ComponentModel.DefaultEventAttribute
+//
+// Authors:
+//     Gonzalo Paniagua Javier (gonzalo@ximian.com)
+//
+// (C) 2002 Ximian, Inc (http://www.ximian.com)
+//
+
+using System;
+
+namespace System.ComponentModel
+{
+       [AttributeUsage(AttributeTargets.Class)]
+       public sealed class DefaultEventAttribute : Attribute
+       {
+               private string eventName;
+
+               public DefaultEventAttribute (string name)
+               {
+                       eventName = name;
+               }
+
+               public string Name
+               {
+                       get { return eventName; }
+               }
+
+               public override bool Equals (object o)
+               {
+                       if (!(o is DefaultEventAttribute))
+                               return false;
+
+                       return (((DefaultEventAttribute) o).eventName == eventName);
+               }
+
+               public override int GetHashCode ()
+               {
+                       return base.GetHashCode ();
+               }
+       }
+}
+