🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.sys.amiga.tech
Article #6210

Re: Gadget Mutual-Exclude

#6210
From: myb100
Date: Wed, 31 Oct 1990 01:58
35 lines
2446 bytes
In article <1990Oct30.071911.5122@iesd.auc.dk>, labben@iesd.auc.dk (Lars Bodin) writes:
> Does anyone out there in NetLand know how to use Mutual-Exclusion between
> gadgets? If so, could you please send me some info on how to do it,
> or even better - a C-source showing what to do.
> 
> Thanks in advance.

Free-Plug time: Have a look at the C-Manual by Anders Bjerin, on FF337. 
It's an excellent guide for people just starting to look at programming
the Amiga (and who are too nervous to look at the RKMs yet :-) ) Plenty
of example code too ! Great effort Anders ! Thanks heaps !!!

Having said that, Anders doesn't give an example of Mutual-Exclude usage, but
does describe it in Chapter 4 'Gadgets'. Briefly: You know where the
Mutual-Exclude field is in the gadget structure ? (just after the GadgetText)
Usually it's set to NULL. To use it, set it the following way:
(paraphrasing the discussion from the Cmanual (without permission))

The decimal number that goes here indicates which gadgets (of the first 32 in
the list) are to be mutually excluded when this one is selected. Let's
say you want to de-select gadgets 0, 2, 5 and 8 when this one is selected.
Write this as 100100101 (read from right to left, starting with gadget#0)
This is = (dec) 293 - and this goes into the mutual-exclude field.
Simple really ! :-) Note that mutual-exclude only works with TOGGLESELECT 
gadgets though.

Hmmm - What do you do though if you have more than 32 gadgets ???
Can anybody answer that one ?

===============================================================================
 Markus Buchhorn                                           ///  | This space
 Mt Stromlo and Siding Spring Observatories, Canberra     ///   | 
 PMB Weston Ck. P.O. A.C.T. 2611, Australia           \\\///    | intentionally
 markus@mso.anu.oz.au  -or-  nssdca::psi%mssso::markus \XX/     | left blank
===============================================================================
Technical Details
Message-ID: <1990Oct31.115852.3209@csc.anu.oz.au>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watserv1!watmath!att!att!linac!pacific.mps.ohio-state.edu!zaphod.mps.ohio-state.edu!samsung!munnari.oz.au!csc.anu.oz.au!myb100
References: <1990Oct30.071911.5122@iesd.auc.dk>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!watserv1!watmath!att!att!linac!pacific.mps.ohio-state.edu!zaphod.mps.ohio-state.edu!samsung!munnari.oz.au!csc.anu.oz.au!myb100
From: myb100@csc.anu.oz.au
Newsgroups: comp.sys.amiga.tech
Subject: Re: Gadget Mutual-Exclude
Message-ID: <1990Oct31.115852.3209@csc.anu.oz.au>
Date: 31 Oct 90 01:58:52 GMT
References: <1990Oct30.071911.5122@iesd.auc.dk>
Organization: Computer Services, Australian National University
Lines: 35