[futurebasic] Re: [FB] Common core code

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : November 1998 : Group Archive : Group : All Groups

From: Peter Bancroft <pbancroft@...>
Date: Mon, 16 Nov 1998 06:43:54 +1100
Phil said -
>>6. Programs MUST fit in to the standard Event construction.
>>What exactly do you mean by this ?
>Gosh, talk about opening up a can of worms. I think with 6 responses, we got
>6 different interpretations. All I had meant by the statement was that code
>should fit in with the standard FB event handling procedures and thus with
>the Mac way of doing things, and not be a program which ignored the event
>handling structure. You've got to have some standard basis for common code.

The can of worms is the Handleevents itself. No other topic has raised so
much discussion over the last few years. Everyone has their own way of
using it!

It would be useful if FB enforced one common Handleevents structure like
RASCAL did years ago.Remember RASCAL - Real Time PASCAL. However this is
BASIC, so getting your head around Handleevents, and how to (mis)use it is
quite a mindbender for some. |-8)

I'm not sure that the FB event handling procedures are the same as the Mac
way of doing things. In MacOS, events buid up in the event queue on an
interrupt driven basis. In FB, every time Handleevents is called, events
are copied from the MacOS event queue into the FB event queue. I used to
think that FBs event queue was interrupt driven. Now I know that it isn't.
That is why I use the following code to get MacOS events faster. I use it
to build, and prioritise, my own event queue. Just my view of things.

Do
  Handleevents
  Fn myHandleevents
Until gEnd

I still like the idea of plugins as a way of extending common code.

Peter		mailto:peter@...		http://www.isoma.com