| 283 | } |
| 284 | |
| 285 | void CInstrumentListCtrl::OnLButtonUp(UINT nFlags, CPoint point) |
| 286 | { |
| 287 | // End a drag operation |
| 288 | if (m_bDragging) { |
| 289 | ReleaseCapture(); |
| 290 | m_bDragging = false; |
| 291 | |
| 292 | CImageList::DragLeave(this); |
| 293 | CImageList::EndDrag(); |
| 294 | m_pDragImage.reset(); // // // |
| 295 | |
| 296 | // Remove highlight |
| 297 | SetItemState(-1, 0, LVIS_DROPHILITED); |
| 298 | RedrawItems(-1, -1); |
| 299 | UpdateWindow(); |
| 300 | |
| 301 | if (m_nDropIndex != -1 && m_nDragIndex != m_nDropIndex) { |
| 302 | // Perform operation |
| 303 | int First = GetInstrumentIndex(m_nDragIndex); |
| 304 | int Second = GetInstrumentIndex(m_nDropIndex); |
| 305 | m_pMainFrame->SwapInstruments(First, Second); |
| 306 | } |
| 307 | } |
| 308 | |
| 309 | CListCtrl::OnLButtonUp(nFlags, point); |
| 310 | } |
nothing calls this directly
no test coverage detected