Re: IOleInPlaceSite::OnUIActivate failing in IE
- From: "Mark Hatsell" <msdnmark@xxxxxxxxxxxxxxxx>
- Date: Mon, 25 Feb 2008 11:51:53 -0000
Hi Charles
Finally worked out what the problem was here after debugging into IE.
Basically my control class needed to have a data member "m_bEnabled" for the
Enabled stock property. IE seems to require this in order to perform UI
Activation on the control and thus allow the interception of keyboard
messages in TranslateAccelerator.
All this happens in the OnUIActivate function in IE. I have given the stack
trace, when clicking on the control in order to UIActivate it, below for
reference.
Thanks.
Mark
mshtml.dll!COleSite::GetBoolPropertyOnObject() + 0x3d bytesmshtml.dll!COleSite::IsEnabled() + 0xa bytes
mshtml.dll!CElement::IsFocussable() + 0x61 bytes
mshtml.dll!CElement::BecomeCurrent() + 0x75 bytes
mshtml.dll!COleSite::CClient::OnUIActivate() + 0xf2 bytes
agraphax.dll!ATL::CComControlBase::InPlaceActivate(long iVerb=-4, const
tagRECT * __formal=0x00c929b0) Line 1016 + 0x27 bytes C++
agraphax.dll!ATL::IOleObjectImpl<agraphaxcontrol>::DoVerbUIActivate(const
tagRECT * prcPosRect=0x00c929b0, HWND__ * __formal=0x00200a84) Line 2153 +
0x11 bytes C++
agraphax.dll!ATL::IOleObjectImpl<agraphaxcontrol>::DoVerb(long iVerb=-4,
tagMSG * __formal=0x00000000, IOleClientSite * pActiveSite=0x03e44088,
tagMSG * __formal=0x00000000, HWND__ * hwndParent=0x00200a84, const tagRECT
* lprcPosRect=0x00c929b0) Line 2226 + 0x13 bytes C++
agraphax.dll!ATL::CComControlBase::OnMouseActivate(unsigned int
__formal=33, unsigned int __formal=33, unsigned int __formal=33, int &
bHandled=1) Line 296 + 0x46 bytes C++
agraphax.dll!ATL::CComControl<agraphaxcontrol,ATL::CWindowImpl<agraphaxcontrol,ATL::CWindow,ATL::CWinTraits<1442840576,0>
unsigned int wParam=788216, long lParam=33619969, long & lResult=-858993460,::ProcessWindowMessage(HWND__ * hWnd=0x00200a84, unsigned int uMsg=33,
unsigned long dwMsgMapID=0) Line 1545 + 0x28 bytes C++
agraphax.dll!agraphaxcontrol::ProcessWindowMessage(HWND__ *
hWnd=0x00200a84, unsigned int uMsg=33, unsigned int wParam=788216, long
lParam=33619969, long & lResult=-858993460, unsigned long dwMsgMapID=0)
Line 124 + 0x1e bytes C++
agraphax.dll!ATL::CWindowImplBaseT<ATL::CWindow,ATL::CWinTraits<1442840576,0>
::WindowProc(HWND__ * hWnd=0x00c929cc, unsigned int uMsg=33, unsigned intwParam=788216, long lParam=33619969) Line 3073 + 0x27 bytes C++
"Charles Wang[MSFT]" <changliw@xxxxxxxxxxxxxxxxxxxx> wrote in message
news:aSAOMPSdIHA.6844@xxxxxxxxxxxxxxxxxxxxxxxxx
Hi Mark,
Thanks for letting me know of this.
You can use Microsoft public symbol server for further debugging. Please
refer to: www.windbg.org.
Now I just get a response that this seems a known issue and you can refer
to the section "Keyboard and mnemonic handling" in this article:
http://msdn2.microsoft.com/en-us/library/ms974281.aspx
For your reading convenience, I extracted part of the contents here:
"The keyboard support included with normal in-place activation only
provides for handling keystrokes in the currently UI active object.
Although this works great for compound documents, where there's usually
only one in-place active object at one time (which is also UI active), it
doesn't work so well for controls where you have many in-place active
objects in the same form or document that would all like certain
keystrokes
to affect them.
With normal in-place activation, the container will forward any keyboard
message to the currently UI active object via
IOleInPlaceActiveObject::TranslateAccelerator. Normally the object will
handle whatever accelerators it wants, returning to the container a code
that indicates whether processing took place. If the object didn't handle
the message, the container gets a shot."
Hope this helps. If you have any other questions or concerns, please feel
free to let me know.
Best regards,
Charles Wang
Microsoft Online Community Support
=====================================================
When responding to posts, please "Reply to Group" via
your newsreader so that others may learn and benefit
from this issue.
======================================================
This posting is provided "AS IS" with no warranties, and confers no
rights.
======================================================
.
- Follow-Ups:
- Re: IOleInPlaceSite::OnUIActivate failing in IE
- From: Charles Wang[MSFT]
- Re: IOleInPlaceSite::OnUIActivate failing in IE
- References:
- IOleInPlaceSite::OnUIActivate failing in IE
- From: Mark Hatsell
- RE: IOleInPlaceSite::OnUIActivate failing in IE
- From: Charles Wang[MSFT]
- Re: IOleInPlaceSite::OnUIActivate failing in IE
- From: Mark Hatsell
- Re: IOleInPlaceSite::OnUIActivate failing in IE
- From: Charles Wang[MSFT]
- IOleInPlaceSite::OnUIActivate failing in IE
- Prev by Date: Re: Passing parameters to a Com DLL
- Next by Date: Deriving a COM interface from another COM interface using ATL/COM
- Previous by thread: Re: IOleInPlaceSite::OnUIActivate failing in IE
- Next by thread: Re: IOleInPlaceSite::OnUIActivate failing in IE
- Index(es):
Relevant Pages
|