Ejemplo n.º 1
0
 /// <summary>
 /// Handles the OnInvalidate event of the Model.
 /// </summary>
 /// <param name="sender">The source of the event.</param>
 /// <param name="e">The <see cref="T:System.EventArgs"/> instance containing the event data.</param>
 void mModel_OnInvalidate(object sender, EventArgs e)
 {
     if (!mIsSuspended)
     {
         parentControl.Invalidate();
     }
 }
Ejemplo n.º 2
0
        void mModel_OnInvalidateRectangle(object sender, RectangleEventArgs e)
        {
            try
            {
                parentControl.Invalidate(Rectangle.Round(e.Rectangle));
            }
            catch (StackOverflowException)
            {
                //TODO: automatic exception report here?

                throw;
            }
        }