I had written: >I have a pop-up list that overlaps with a gadget when it pops up. >Otherwise it is separated from the gadget. When I pop up the list >and make a selection, the penUpEvent from the selection will get sent >to the gadget after the selection is made (in addition to acting >correctly on the pop-up list). My gadget needs to react to a penUpEvent >to perform some other functionality, but I don�t want it to react to >the penUpEvent that was left over from making a selection in a pop-up list. >First of all, why is this penUnEvent being sent to my gadget? Secondly, >how can I prevent this unintended action?
After looking at it more closely, I think I can answer my own question. The penUpEvent comes to the overall form event handler before it is looked at by default handlers. I had been qualifying the penUpEvent based only on the bounds of the gadget, so at that point it is not yet known whether some other object wants to handle that event. The solution that I eventually used was to define a static flag, "IgnorePenUp" which I set whenever and popSelectEvent is received. This flag causes my custom handling of the penUpEvent to be suppressed. Then I re-enable the action by setting IgnorePenUp=0 upon receipt of a nilEvent. Robert Scott, Ypsilanti, MI (reply through this forum, not by e-mailing me directly) -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
