Path: utzoo!utgpu!jarvis.csri.toronto.edu!mailrus!eecae!netnews.upenn.edu!rutgers!bellcore!texbell!uhnix1!sugar!peter From: peter@sugar.uu.net (Peter da Silva) Newsgroups: comp.sys.amiga.tech Subject: Re: inputs from many windows. Keywords: windows, messages, IDCMP, stupid! Message-ID: <3358@sugar.uu.net> Date: 29 Jan 89 00:51:21 GMT References: <1918@pur-phy> Distribution: comp.sys.amiga.tech Organization: Sugar Land Unix - Houston, TX Lines: 22 Browser 1.2 and 1.3 just opened an IDCMP for each window, and had a loop like this: while(1) { Wait(sigmask); /* sigmask is OR of all ports' sigbits */ for(each window, w) { while(msg = GetMsg(w->UserPort->mp_SigBits)) { copymsg = *msg; /* structure copy */ ReplyMsg(msg); switch(copymsg.Class) { ... } } } } Browser 1.4 and 1.5 had one IDCMP shared between all the windows, and used CLoseWindowSafely(). Unfortunately, it wasn't safe. So 1.6 has gone back to one IDCMP per window. -- Peter "Have you hugged your wolf today" da Silva `-_-' Hackercorp. ...texbell!sugar!peter, or peter@sugar.uu.net 'U`