[Bug 52327] Wrong WM_CONTEXTMENU message default processing

WineHQ Bugzilla wine-bugs at winehq.org
Mon Jan 3 13:57:06 CST 2022


https://bugs.winehq.org/show_bug.cgi?id=52327

--- Comment #4 from YAL <yal at csoftcom.com> ---
Software is nanoCAD CAD solution and I'm responsible for adapting it under
*nix. 
I can write test - VS studio project? Or just exe file? 

I've sent to screenshots illustrated this bug - first under WINE, second under
Windows. Difference in pWnd argument which in first case pointed to toplevel
child (CMFCTabCtrl) and in second (right case) to nearest (CMDICliaentAreaWnd).


void CMDIFrameWndEx::OnContextMenu(CWnd* pWnd, CPoint point)
{
    if (m_wndClientArea.GetMDITabs().GetSafeHwnd() == NULL)
    {
        Default();
        return;
    }

    if (CMFCPopupMenu::GetActiveMenu() != NULL)
    {
        return;
    }

    if ((GetAsyncKeyState(::GetSystemMetrics(SM_SWAPBUTTON) ? VK_RBUTTON :
VK_LBUTTON) & 0x8000) != 0) // "Left" mouse button is pressed
    {
        return;
    }

    if (pWnd->GetSafeHwnd() == m_wndClientArea.GetSafeHwnd()) <=== This case
not working under WINE - wrong child
    {
        CWnd* pWndCur = WindowFromPoint(point);

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list