[comp.sys.amiga] Only 31 Intuiclasses?

john13@garfield.UUCP (John Russell) (02/25/88)

In article <1026@radio.toronto.edu> cks@radio.UUCP (Chris Siebenmann) writes:
>
> I would argue against this because it does something that's already
>easy to do (check for RAWKEY code == 0x5f) and because there are only
>31 Intuition message classes possible, and I'd like to preserve as
>many as possible for future message classes. 

Is it actually necessary to impose a limit of distinct bit positions? For the
window IDCMPFlags I can see, but isn't all Intuimessage processing done with

case CLASS1:
case CLASS2:

etc which would work just as well with 1,2,3,4... as with 1,2,4,8...?

If so (although it's entirely possible I'm overlooking something obvious)
then there might be future I-Flags such as LISTEN_FOR_WEIRD_KEYS which would
only take up 1 bit in the flags structure but which would cause your
window to receive HELPKEY, F1KEY, CURSORUPKEY, etc.

Would this be possible (desirable, compatible, insert your own adjective)?

John
-- 
"Fanaticism is all right... as long as you're ALONE! HAHAHAHA!"
		-- Pat Robertson shares a gem of wisdom told to him by Richard 
		   Nixon, and thus becomes the first politician to whom I can
		   honestly apply the term "scares the willies out of me"

kenchiu@phoenix.Princeton.EDU (Kenneth Chiu) (02/27/88)

In article <4531@garfield.UUCP> john13@garfield.UUCP (John Russell) writes:
>Is it actually necessary to impose a limit of distinct bit positions? For the
>window IDCMPFlags I can see, but isn't all Intuimessage processing done with
>
>case CLASS1:
>case CLASS2:

This is something I've wondered about.  Sometimes I use (flag & CLASS1),
but I've never noticed more than one class being set at a time.  So could we
actually have 2^32 different classes?  Or is there some funniness that
I've never run across.

Ken Chiu

cks@radio.toronto.edu (Chris Siebenmann) (02/29/88)

In article <4531@garfield.UUCP> john13@garfield.UUCP (John Russell) writes:
...
> Is it actually necessary to impose a limit of distinct bit positions? For the
> window IDCMPFlags I can see, but isn't all Intuimessage processing done with
> 
> case CLASS1:
> case CLASS2:
> 
> etc which would work just as well with 1,2,3,4... as with 1,2,4,8...?

 The problem is things like ModifyIDCMP() and NewWindow structures, to
which you supply OR-ed together flags. In addition, the application
I'm working on now uses message masks to decide what routine to
dispatch a given message to, and Intuition presumably uses the mask
internally to decide whether to send a window a given event. You might
be able to do it for new message classes, but it would probably take
too much effort to be really useful.

-- 
	You're a prisoner of the dark sky/The propeller blades are still
	And the evil eye of the hurricane's/Coming in for the kill
Chris Siebenmann		{allegra,mnetor,decvax,pyramid}!utgpu!radio!cks
cks@radio.toronto.edu	     or	...!utgpu!{chp!hak!ziebmef,ontmoh}!cks