Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!swrinde!zaphod.mps.ohio-state.edu!ub!dsinc!bagate!cbmvax!peter From: peter@cbmvax.commodore.com (Peter Cherna) Newsgroups: comp.sys.amiga.tech Subject: Re: Gadget Mutual-Exclude Message-ID: <15520@cbmvax.commodore.com> Date: 1 Nov 90 16:56:01 GMT References: <1990Oct31.115852.3209@csc.anu.oz.au> <1990Oct30.071911.5122@iesd.auc.dk> Reply-To: peter@cbmvax.commodore.com (Peter Cherna) Organization: Commodore, West Chester, PA Lines: 35 In article ggk@tirith.UUCP (Gregory Kritsch) writes: >myb100@csc.anu.oz.au writes: >Actually, the cute part of the whole thing is the fact that gadget >mutual exclusion doesn't work, unless you code it youself. Further, >Commodore's definition of it was that it would DISABLE, not deselect, >the listed gadgets. Gadget mutual exclusion is indeed not supported through the original defined interface. It wouldn't have worked very well that way. Under 2.0, the Gadget Toolkit implements easy mutual exclusion, and the new custom gadget stuff makes mutual exclusion much easier. >Basically, what I've always done is to self-code the exclusion algorithm >for both en/disabling gadgets and (de)selecting them into my GADGETUP >code. There are several restrictions you have to follow to do mutual exclusion correctly. See the AmigaMail article and the 1.3 ROM Kernel Manual for full details. One restriction is that you MUST use GADGIMMEDIATE (not RELVERIFY) gadgets, and do your selection changes upon receiving GADGETDOWN (not GADGETUP) messages. You should use gadgets whose imagery is an Image (GADGIMAGE) and is highlighted with another image (GADGHIMAGE) or by complementing (GADGHCOMP). You cannot use things like gadgets whose imagery is a Border plus IntuiText having GADGHCOMP highlighting. > Gregory Kritsch | University of Waterloo Peter -- Peter Cherna, Software Engineer, Commodore-Amiga, Inc. {uunet|rutgers}!cbmvax!peter peter@cbmvax.cbm.commodore.com My opinions do not necessarily represent the opinions of my employer. "She read him like a book: she liked to peek at his end."