MCPcopy Create free account
hub / github.com/BeneficialCode/WinArk / OnMouseMove

Method OnMouseMove

WinArk/HexControl.cpp:541–554  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

539}
540
541LRESULT CHexControl::OnMouseMove(UINT, WPARAM, LPARAM lParam, BOOL&) {
542 if (GetCapture() != m_hWnd)
543 return 0;
544
545 POINT pt = { GET_X_LPARAM(lParam),GET_Y_LPARAM(lParam) };
546 auto offset = GetOffsetFromPoint(pt);
547 if (offset > m_EndOffset)
548 offset = m_EndOffset;
549
550 m_Selection.SetSimple(std::min(offset, m_CaretOffset), abs(offset - m_CaretOffset));
551 RedrawWindow();
552
553 return 0;
554}
555
556LRESULT CHexControl::OnLeftButtonUp(UINT, WPARAM, LPARAM, BOOL&) {
557 ReleaseCapture();

Callers

nothing calls this directly

Calls 1

SetSimpleMethod · 0.80

Tested by

no test coverage detected