private void pictureBox1_MouseUp(object sender, MouseEventArgs e) { isMouse = false; arrayPoints.ResetPoints(); if (crc_OK == true) { Graphics gr = pictureBox1.CreateGraphics(); gr.DrawEllipse(pen, firstp.X, firstp.Y, e.X - firstp.X, e.Y - firstp.Y); crc_OK = false; } else if (rec_OK == true) { Graphics gr = pictureBox1.CreateGraphics(); gr.DrawRectangle(pen, firstp.X, firstp.Y, e.X - firstp.X, e.Y - firstp.Y); rec_OK = false; } else { return; } }
private void secondCanvas_MouseUp(object sender, MouseEventArgs e) { isMousePressed = false; secondArrayPoints.ResetPoints(); } // непосредственно рисование на втором холсте
} // нажатие на холст private void firstCanvas_MouseUp(object sender, MouseEventArgs e) { isMousePressed = false; firstArrayPoints.ResetPoints(); } // отжатие холста :)