Re: Tabbing Between and Inside WebBrowser Ctrl and other Controls
From: Igor Tandetnik (itandetnik_at_mvps.org)
Date: 06/02/04
- Next message: serge: "Getting pure HTML"
- Previous message: Apurva Lawale: "Tabbing Between and Inside WebBrowser Ctrl and other Controls"
- In reply to: Apurva Lawale: "Tabbing Between and Inside WebBrowser Ctrl and other Controls"
- Messages sorted by: [ date ] [ thread ]
Date: Wed, 2 Jun 2004 15:46:05 -0400
"Apurva Lawale" <apudeepa@pacific.net.sg> wrote in message
news:ucXZNfMSEHA.3848@TK2MSFTNGP09.phx.gbl
> I have made a dll which hosts all the functions related to WebBrowser
> Hosting. I even managed to get key events worked inside the dll.
>
> This allows me to create a webbrowser ctrl in a window and also
> allows me to use the Tab key inside the webbrowser control. But now I
> am having a problem of getting it to tab to other controls in the
> window.
>
> How do I make it work such that the Tabs in the web browser control
> work and also I manage to Tab through rest of the controls in the
> window.
This is how I do it. Preprocess window messages at the message pump
(right after GetMessage but before DispatchMessage). MFC has
PreTranslateMessage method for it, other frameworks provide similar
facilities. If the message happens to be a keyboard message, check
whether HWND of the message is a descendant (a direct or indirect child)
or WebBrowser control window, using IsChild API. If it is, call
IOleInPlaceActiveObject::TranslateAccelerator on WebBrowser. If this
call returns S_FALSE, or if the window was not the child of WB in the
first place, call IsDialogMessage on the dialog.
--
With best wishes,
Igor Tandetnik
"For every complex problem, there is a solution that is simple, neat,
and wrong." H.L. Mencken
- Next message: serge: "Getting pure HTML"
- Previous message: Apurva Lawale: "Tabbing Between and Inside WebBrowser Ctrl and other Controls"
- In reply to: Apurva Lawale: "Tabbing Between and Inside WebBrowser Ctrl and other Controls"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|