Path: utzoo!attcan!uunet!decwrl!bacchus.pa.dec.com!may.pa.dec.com!may From: may@may.pa.dec.com (G. May Yip) Newsgroups: comp.windows.x.motif Subject: MenuBar question Message-ID: <1990Oct15.232357.17960@wrl.dec.com> Date: 15 Oct 90 23:23:57 GMT Sender: news@wrl.dec.com (News) Reply-To: may@may.pa.dec.com (G. May Yip) Organization: DEC Palo Alto Lines: 25 Hi there, I wonder if it is legal to construct a Motif menubar such that some of the cascade buttons don't have any pulldown menu and command button(s) as children? That is, I'd like to set it up such that a callback routine is attached to the cascade button, rather than to the command button(s) inside the pulldown menu, as is usually done. I tried to do some but ran into some problem :( The callback triggered by the cascade button performs some Xlib operations and then pops up a widget, asking user for a mouse button click. The problem I'm experiencing is that instead of 1 mouse button click I need to actually click TWICE to get the thing thru. I suspect this is because my cascade button doesn't have any command button(s) as children, therefore it is still waiting for the xtra mouse button release event that is usually supplied with clicking on a command button inside the pulldown. I tried to "simulate" this xtra mouse button event (via XSendEvent) but it didn't work (the program died) - either because Motif doesn't like XSendEvent or I wasn't doing it right. Does any know anything about this? Did anyone try constructing attaching callbacks to cascade buttons rather than to command buttons? Any pointer will be appreciated! Desperately awaiting your help, /may