Tab key support in an IWebBrowser2 control

后端 未结 2 1064
囚心锁ツ
囚心锁ツ 2020-12-21 04:56

I have an embedded IWebBrowser2 control using straight C++ (windowed, not windowless) and when someone hits the Tab key to go between fields in the browser, it jumps focus o

2条回答
  •  星月不相逢
    2020-12-21 05:35

    Accelerator keystrokes like tab are handled by the message loop before being dispatched. As such a hook function needs to be called by a message loop - IOleInPlaceActiveObject::TranslateAccelerator iirc. - to give the control the chance to do keyboard navigation type things.

提交回复
热议问题