Xref: utzoo comp.windows.x:34904 comp.windows.x.motif:2451 Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!sdd.hp.com!zaphod.mps.ohio-state.edu!samsung!pan!ctron.com!pel From: pel@ctron.com (Paul Leclerc) Newsgroups: comp.windows.x,comp.windows.x.motif Subject: Re: Secondary Loop (within XtMainLoop) Problems Message-ID: Date: 4 Apr 91 18:37:58 GMT References: <1991Apr2.080151.10992@neon.Stanford.EDU> <1991Apr3.092416.8894@siesoft.co.uk> Sender: pel@pan.ctron.com Followup-To: comp.windows.x Organization: Cabletron Systems Inc. Lines: 32 In-reply-to: paulb@siesoft.co.uk's message of 3 Apr 91 09:24:16 GMT In article <1991Apr3.092416.8894@siesoft.co.uk> paulb@siesoft.co.uk (Paul Bentley) writes: > I have also experienced considerable difficulty in making subsiduary > event loops work in Motif 1.1 and have spent several days producing short > (50 lines approx.) example programs. The manifestation of these problems > are in my experience always obscure, so obscure infact that you have to > spend a lot of time convincing yourself that you have not made the mistake > in your own code. > > My opinion is that any problem caused by the use of subsiduary event loops > is a bug. I have never seen anything in writing to say that they are not > allowed, and the bugs that appear are just too obscure to be features. In fact, in the Motif book by Douglas Young, he suggests that the only way to have blocking dialog boxes is to use another event loop ( page 116). Of course no other mention is made nor any explanation made as to how you go about doing this (for us X/Motif novices) > However I do accept the point of view that subsiduary event loops should be > avoided. So then how do we write dialog boxes or other things that block until certain events occur? > My advice would be not to write any new applications using subsiduary > event loops. I'm in the unfortunate position of maintaining old code ported > to Motif (far from ideal) which has blocking subsiduary event loops called > from 70 places ! Paul L. -- pel@ctron.com #include Cabletron Systems Inc.