unsafe HRESULT IOleControlSite.TranslateAccelerator(User32.MSG* pMsg, KEYMODIFIERS grfModifiers) { if (pMsg is null) { return HRESULT.E_POINTER; } Debug.Assert(!_host.GetAxState(s_siteProcessedInputKey), "Re-entering IOleControlSite.TranslateAccelerator!!!"); _host.SetAxState(s_siteProcessedInputKey, true); Message msg = *pMsg; try { bool f = _host.PreProcessMessage(ref msg); return f ? HRESULT.S_OK : HRESULT.S_FALSE; } finally { _host.SetAxState(s_siteProcessedInputKey, false); } }