Ejemplo n.º 1
0
 /// <summary>
 ///
 /// </summary>
 /// <param name="e"></param>
 protected override void OnMouseUp(MouseEventArgs e)
 {
     base.OnMouseUp(e);
     base.UpdateViewInfoState();
     if (e.Button == MouseButtons.Left)
     {
         EditHitInfo info1 = ViewInfo.CalcHitInfo(new Point(e.X, e.Y));
         EditHitInfo info2 = ViewInfo.PressedInfo;
         ClearHotPressed();
         if ((info2 != null) && (info2.HitTest == EditHitTest.Button))
         {
             NotifyButtonStateChanged((info2.HitObject as EditorButtonObjectInfoArgs).Button);
         }
         if ((AllowButtonPress && !info1.IsEmpty) && (ViewInfo.CompareHitInfo(info1, info2) && (info1.HitTest == EditHitTest.Button)))
         {
             OnClickButton(info1.HitObject as EditorButtonObjectInfoArgs);
         }
     }
 }