Please note that as of October 24, 2014, the Nokia Developer Wiki will no longer be accepting user contributions, including new entries, edits and comments, as we begin transitioning to our new home, in the Windows Phone Development Wiki. We plan to move over the majority of the existing entries over the next few weeks. Thanks for all your past and future contributions.
Talk:How to Handle Pointer Events in a Custom Control
Handling pointer events in custom controls is often require during developing custom GUI applications. This article demonstrates how pointer position will validated against the control rectangle and the pointer events will be routed to appropriate control. The article is well explained and useful to beginners.
This piece of code works, but logically error. CCoeControl::HandlePointerEventL(aPointerEvent); will dispatch the pointer event to proper control automatically, so the if blocks just redo the logical already provided by CCoeControl. And thus give a bad impression to developer that they have to maintain the pointer dispatching stuff by themselves in a container.(Just like the key process)
You need to do the dispatch by yourself only when the control contained by the container can't be accessed by container's CCoeControl *ComponentControl(TInt aIndex) const; function. Most time that's an error
User:bibu2651 17:10, 26 Jan 2010