X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/b3818fbe8e439bc9af8c20371774520a5a2bc9c7..4438caf41af49f00f3c8137ac801871f59cce386:/src/msw/mdi.cpp diff --git a/src/msw/mdi.cpp b/src/msw/mdi.cpp index 0a43426620..551c1cc4ec 100644 --- a/src/msw/mdi.cpp +++ b/src/msw/mdi.cpp @@ -537,10 +537,7 @@ bool wxMDIParentFrame::MSWTranslateMessage(WXMSG* msg) return TRUE; } - if ( m_acceleratorTable.Ok() && - ::TranslateAccelerator(GetHwnd(), - GetTableHaccel(m_acceleratorTable), - pMsg) ) + if ( m_acceleratorTable.Translate(this, msg) ) { return TRUE; } @@ -993,15 +990,7 @@ long wxMDIChildFrame::MSWDefWindowProc(WXUINT message, WXUINT wParam, WXLPARAM l bool wxMDIChildFrame::MSWTranslateMessage(WXMSG* msg) { - MSG *pMsg = (MSG *)msg; - if ( m_acceleratorTable.Ok() ) - { - return ::TranslateAccelerator(GetWinHwnd(GetParent()), - GetTableHaccel(m_acceleratorTable), - pMsg) != 0; - } - - return FALSE; + return m_acceleratorTable.Translate(GetParent(), msg); } // ---------------------------------------------------------------------------