Merge pull request #3018 from ludovic-henry/coop-marshal-attach
[mono.git] / mcs / class / System.Windows.Forms / System.Windows.Forms / StatusBarPanelClickEventArgs.cs
index 3f8fc50e254cd45db538daacd33e93bb77aa2f7c..6c92e0d14109a420cc1779fd6342d50d15f07164 100644 (file)
-//\r
-// System.Windows.Forms.StatusBarPanelClickEventArgs\r
-//\r
-// Author:\r
-//   stubbed out by Richard Baumann (biochem333@nyc.rr.com)\r
-//      Partially completed by Dennis Hayes (dennish@raytek.com)\r
-//   Gianandrea Terzi (gianandrea.terzi@lario.com)\r
-//\r
-// (C) Ximian, Inc., 2002\r
-//\r
-\r
-namespace System.Windows.Forms {\r
-\r
-       /// <summary>\r
-       /// Provides data for the PanelClick event.\r
-       /// </summary>\r
-       public class StatusBarPanelClickEventArgs : MouseEventArgs {\r
-\r
-               private StatusBarPanel panel;\r
-\r
-               /// --- Constructor ---\r
-               public StatusBarPanelClickEventArgs(StatusBarPanel panel, MouseButtons button, int clicks, int x, int y) : base(button, clicks, x, y, 0) \r
-               {\r
-                       this.panel = panel;\r
-               }\r
-\r
-               #region Public Properties\r
-               \r
-               /// <summary>\r
-               ///     StatusBarPanel Property\r
-               /// </summary>\r
-               ///\r
-               /// <remarks>\r
-               ///     Gets the StatusBarPanel to draw.\r
-               /// </remarks>\r
-               public StatusBarPanel StatusBarPanel \r
-               {\r
-                       get \r
-                       {\r
-                               return panel;\r
-                       }\r
-               }\r
-\r
-\r
-               #endregion\r
-\r
-               #region Public Methods\r
-               /// <summary>\r
-               ///     Equality Operator\r
-               /// </summary>\r
-               ///\r
-               /// <remarks>\r
-               ///     Compares two StatusBarPanelClickEventArgs objects.\r
-               ///     The return value is based on the equivalence of\r
-               ///     the StatusBarPanel, Button, Clicks, X, and Y\r
-               ///     properties of the two StatusBarPanelClickEventArgs.\r
-               /// </remarks>\r
-               public static bool operator == (StatusBarPanelClickEventArgs objA, StatusBarPanelClickEventArgs objB) \r
-               {\r
-                       return ((objA.panel == objB.panel) && (objA.Button == objB.Button) && (objA.Clicks == objB.Clicks) && (objA.X == objB.X) && (objA.Y == objB.Y));\r
-               }\r
-               \r
-               /// <summary>\r
-               ///     Inequality Operator\r
-               /// </summary>\r
-               ///\r
-               /// <remarks>\r
-               ///     Compares two StatusBarPanelClickEventArgs objects.\r
-               ///     The return value is based on the equivalence of\r
-               ///     the StatusBarPanel, Button, Clicks, X, and Y\r
-               ///     properties of the two StatusBarPanelClickEventArgs.\r
-               /// </remarks>\r
-               public static bool operator != (StatusBarPanelClickEventArgs objA, StatusBarPanelClickEventArgs objB) \r
-               {\r
-                       return ((objA.panel != objB.panel) || (objA.Button != objB.Button) || (objA.Clicks != objB.Clicks) || (objA.X != objB.X) || (objA.Y != objB.Y));\r
-               }\r
-\r
-               /// <summary>\r
-               ///     Equals Method\r
-               /// </summary>\r
-               ///\r
-               /// <remarks>\r
-               ///     Checks equivalence of this\r
-               ///     StatusBarPanelClickEventArgs and another\r
-               ///     object.\r
-               /// </remarks>\r
-               public override bool Equals (object obj) \r
-               {\r
-                       if (!(obj is StatusBarPanelClickEventArgs))return false;\r
-                       return (this == (StatusBarPanelClickEventArgs) obj);\r
-               }\r
-\r
-               /// <summary>\r
-               ///     GetHashCode Method\r
-               /// </summary>\r
-               ///\r
-               /// <remarks>\r
-               ///     Calculates a hashing value.\r
-               /// </remarks>\r
-               public override int GetHashCode () \r
-               {\r
-                       return unchecked(panel.GetHashCode() * base.GetHashCode());\r
-               }\r
-\r
-               /// <summary>\r
-               ///     ToString Method\r
-               /// </summary>\r
-               ///\r
-               /// <remarks>\r
-               ///     Formats the StatusBarPanelClickEventArgs as a string.\r
-               /// </remarks>\r
-               [MonoTODO]\r
-               public override string ToString () \r
-               {\r
-                       //FIXME: add class specific stuff;\r
-                       return base.ToString();\r
-               }\r
-               #endregion\r
-\r
-       }\r
-}\r
+// Permission is hereby granted, free of charge, to any person obtaining
+// a copy of this software and associated documentation files (the
+// "Software"), to deal in the Software without restriction, including
+// without limitation the rights to use, copy, modify, merge, publish,
+// distribute, sublicense, and/or sell copies of the Software, and to
+// permit persons to whom the Software is furnished to do so, subject to
+// the following conditions:
+//
+// The above copyright notice and this permission notice shall be
+// included in all copies or substantial portions of the Software.
+//
+// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
+// EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+// MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
+// NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
+// LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
+// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
+// WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
+//
+// Copyright (c) 2004 Novell, Inc.
+//
+// Authors:
+//     Jackson Harper (jackson@ximian.com)
+
+
+using System;
+
+namespace System.Windows.Forms {
+
+       public class StatusBarPanelClickEventArgs : MouseEventArgs {
+
+               private StatusBarPanel panel;
+
+               public StatusBarPanelClickEventArgs (StatusBarPanel statusBarPanel,
+                               MouseButtons button, int clicks, int x, int y) :
+                       base (button, clicks, x, y, 0)
+               {
+                       this.panel = statusBarPanel;
+               }
+
+               public StatusBarPanel StatusBarPanel {
+                       get { return panel; }
+               }
+       }
+}
+