// // System.Windows.Forms.StatusBarPanelClickEventArgs // // Author: // stubbed out by Richard Baumann (biochem333@nyc.rr.com) // Partially completed by Dennis Hayes (dennish@raytek.com) // Gianandrea Terzi (gianandrea.terzi@lario.com) // // (C) Ximian, Inc., 2002 // namespace System.Windows.Forms { /// /// Provides data for the PanelClick event. /// public class StatusBarPanelClickEventArgs : MouseEventArgs { private StatusBarPanel panel; /// --- Constructor --- public StatusBarPanelClickEventArgs(StatusBarPanel panel, MouseButtons button, int clicks, int x, int y) : base(button, clicks, x, y, 0) { this.panel = panel; } #region Public Properties /// /// StatusBarPanel Property /// /// /// /// Gets the StatusBarPanel to draw. /// public StatusBarPanel StatusBarPanel { get { return panel; } } #endregion #region Public Methods /// /// Equality Operator /// /// /// /// Compares two StatusBarPanelClickEventArgs objects. /// The return value is based on the equivalence of /// the StatusBarPanel, Button, Clicks, X, and Y /// properties of the two StatusBarPanelClickEventArgs. /// public static bool operator == (StatusBarPanelClickEventArgs objA, StatusBarPanelClickEventArgs objB) { return ((objA.panel == objB.panel) && (objA.Button == objB.Button) && (objA.Clicks == objB.Clicks) && (objA.X == objB.X) && (objA.Y == objB.Y)); } /// /// Inequality Operator /// /// /// /// Compares two StatusBarPanelClickEventArgs objects. /// The return value is based on the equivalence of /// the StatusBarPanel, Button, Clicks, X, and Y /// properties of the two StatusBarPanelClickEventArgs. /// public static bool operator != (StatusBarPanelClickEventArgs objA, StatusBarPanelClickEventArgs objB) { return ((objA.panel != objB.panel) || (objA.Button != objB.Button) || (objA.Clicks != objB.Clicks) || (objA.X != objB.X) || (objA.Y != objB.Y)); } /// /// Equals Method /// /// /// /// Checks equivalence of this /// StatusBarPanelClickEventArgs and another /// object. /// public override bool Equals (object obj) { if (!(obj is StatusBarPanelClickEventArgs))return false; return (this == (StatusBarPanelClickEventArgs) obj); } /// /// GetHashCode Method /// /// /// /// Calculates a hashing value. /// public override int GetHashCode () { return unchecked(panel.GetHashCode() * base.GetHashCode()); } /// /// ToString Method /// /// /// /// Formats the StatusBarPanelClickEventArgs as a string. /// [MonoTODO] public override string ToString () { //FIXME: add class specific stuff; return base.ToString(); } #endregion } }