| 1597 | } |
| 1598 | |
| 1599 | void CColorCopDlg::OnLButtonDblClk(UINT nFlags, CPoint point) { |
| 1600 | HWND CCopHWND = AfxGetApp()->GetMainWnd()->m_hWnd; |
| 1601 | |
| 1602 | CWnd* pWnd = ChildWindowFromPoint(point); |
| 1603 | |
| 1604 | if (pWnd && pWnd->GetSafeHwnd() == m_ColorPreview.GetSafeHwnd()) { |
| 1605 | // User double-clicked the color preview: open the custom color dialog |
| 1606 | OnColorPick(); |
| 1607 | return; |
| 1608 | } else if (pWnd && pWnd->GetSafeHwnd() == m_MagWindow.GetSafeHwnd()) { |
| 1609 | if (hBitmap) { |
| 1610 | CString strQuestion; |
| 1611 | strQuestion.LoadString(IDS_COPY_BITMAP); |
| 1612 | |
| 1613 | if (IDYES == AfxMessageBox(strQuestion, MB_YESNO)) { |
| 1614 | if (::OpenClipboard(CCopHWND)) { |
| 1615 | ::EmptyClipboard(); |
| 1616 | |
| 1617 | hBitmapClip = CopyBitmap(hBitmap); |
| 1618 | SetClipboardData(CF_BITMAP, hBitmapClip); |
| 1619 | ::CloseClipboard(); |
| 1620 | return; |
| 1621 | } |
| 1622 | } |
| 1623 | } |
| 1624 | } else if (pWnd && pWnd->GetSafeHwnd() == m_MagPlus.GetSafeHwnd()) { |
| 1625 | // treat double click on mag plus like two clicks |
| 1626 | CColorCopDlg::OnLButtonDown(nFlags, point); |
| 1627 | return; |
| 1628 | |
| 1629 | } else if (pWnd && pWnd->GetSafeHwnd() == m_MagMinus.GetSafeHwnd()) { |
| 1630 | // treat double click on mag minus like two clicks |
| 1631 | CColorCopDlg::OnLButtonDown(nFlags, point); |
| 1632 | return; |
| 1633 | |
| 1634 | } else { |
| 1635 | SetCursor(m_hStandardCursor); // put standard cursor back on |
| 1636 | return; |
| 1637 | } |
| 1638 | CDialog::OnLButtonDblClk(nFlags, point); |
| 1639 | } |
| 1640 | |
| 1641 | void CColorCopDlg::OnThemeSystem() { |
| 1642 | m_Appflags &= ~DarkMode; // clear dark bit |
nothing calls this directly
no outgoing calls
no test coverage detected