void CSizeEditor::OnMouseMove(UINT nFlags, CPoint point) { CRect rect; GetClientRect(rect); if ((nFlags & MK_LBUTTON) && (m_iButtonPressed == 3)) { // Drag static int LastY; if (LastY - point.y > 0) IncreaseValue(); else if (LastY - point.y < 0) DecreaseValue(); LastY = point.y; RedrawWindow(NULL); } else { MouseAction(nFlags, point); if (!(nFlags & MK_LBUTTON)) { if ((point.x > rect.bottom) && (point.x < (rect.right - rect.bottom))) m_bSizeCursor = true; else m_bSizeCursor = false; } } }
void CSizeEditor::OnLButtonDown(UINT nFlags, CPoint point) { CRect rect; GetClientRect(rect); SetCapture(); if ((point.x > rect.bottom) && (point.x < (rect.right - rect.bottom))) { m_iButtonPressed = 3; } else MouseAction(nFlags, point); }
void CSizeEditor::OnLButtonDblClk(UINT nFlags, CPoint point) { MouseAction(nFlags, point); }