John Marshall <[EMAIL PROTECTED]> writes: > On Mon, Jan 07, 2002 at 10:15:51AM -0800, Dave Carrigan wrote: > > However, if I set the event's data to the value 262, the program fails. > > It appears that something inside PalmOS wants to handle the event, > > because the event gets eaten, and a spurious menuCmdBarOpenEvent is > > generated. If I use any other value in the data then my form sees the > > event and pops up the alert. > > (Did you really test all 65535 other values? :-))
Heh, no. The problem cropped up with an old program of mine, where I was using custom events to pass messages between forms. These days, I use features, but back then I didn't. The datum in question contains the record id that the form is to open, and the program is only now getting old enough that some users have more than 262 records. All I can say is that values [0..261,263..265] had no problems. > If you instrument your sample program, you will see that it is > MenuHandleEvent that is eating the event. Yes, I forget to mention that. > * Sidestepping MenuHandleEvent when the event has your custom event > type; Yes, this is what I also determined. However, this does not completely fix the problem. That was my first attempt at a solution: whenever I got a event with eType >= firstUserEvent, I just called FrmDispatchEvent directly. But, there is still something fscking with the event, maybe in FrmDispatchEvent, and there is corruption happening somewhere else in palmos, because shortly after receiving the firstUserEvent and filling in the form, pose ends up hanging so hard I have to kill it. However, if I attach gdb to pose, it doesn't hang, and my form works fine. I couldn't duplicate this in the test program. I solved the problem for me by losing the custom event altogether and using features to pass the messages around. It's possible that it's my program that is somehow corrupting palmos, but if so, it only corrupts palmos 3.5, and only when it creates an event with the value of 262. Cheers, -- Dave Carrigan ([EMAIL PROTECTED]) | Yow! I'm encased in the lining UNIX-Apache-Perl-Linux-Firewalls-LDAP-C-DNS | of a pure pork sausage!! Seattle, WA, USA | http://www.rudedog.org/ | -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/tech/support/forums/
