[futurebasic] Re: [FB] [FB3]progressBar

Message: < previous - next > : Reply : Subscribe : Cleanse
Home   : April 2000 : Group Archive : Group : All Groups

From: "Brian J. Hughes" <BrianHughes@...>
Date: Wed, 12 Apr 2000 00:55:34 -0700
At 3:15 PM +1000 on 4/12/00, Robin wrote:


> > For those interested, the following demo shows how to use btnType 81 to
>> create a progress bar.  Works with OS 9 and FB^3 using FBII runtime.
>
>Does anyone know a similar method for doing the OS8+ "barber-pole" progress
>bar used to show something is happening when the endpoint isn't known?

Funny you should ask...

I stayed up way to late last night playing with the source from that progress bar demo.  I wondered what other fun could be had if I changed the button type number.  You can get all sorts of strange things.

But to your specific question, I found this would make a barber pole:

add this line
Include "{FB3}:FB Extensions:Compiler:Headers:Tlbx Appearance.Incl"

and this line (I added it inside FN setBtn):

OSErr = FN SetControlData (btnValue&,129,_"inde",0,0)

Actually _"inde" is kControlProgressBarIndeterminateTag in the include file.

That turned the button into a barber pole.  I haven't looked deep enough to figure out how to animate it though.  As it is it's static.

Maybe someone else knows, I'm swamped with homework so I can't look into it deeper.

I did see one clue in the MacOS 8 Control Manager Inside Mac.  It mentions the barber pole as being animated at idle time.  Calling a function called IdleControls for the window seems to be included the process as well as some confusing stuff about responding to messages about control features.

Rather confused,

Brian Hughes