Welcome to the MacNN Forums.

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

You are here: MacNN Forums > Software - Troubleshooting and Discussion > Developer Center > Can I stop a determinate progress bar from animating?

Can I stop a determinate progress bar from animating?
Thread Tools
Professional Poster
Join Date: Sep 2000
Location: San Francisco
Status: Offline
Reply With Quote
Apr 7, 2003, 02:17 PM
 
I have a determinate progress bar in my application that gets updated every five minutes and moves very slowly. Is there a way to prevent the barbershop effect from spinning? It seems to take a lot of memory. The stopAnimation: method only seems to work on indeterminate progress indicators.

thanks,
kman
     
kman42  (op)
Professional Poster
Join Date: Sep 2000
Location: San Francisco
Status: Offline
Reply With Quote
Apr 9, 2003, 01:25 PM
 
I can't believe this isn't possible. Could I sublclass the progress bar and override the animation method? Not really sure how to do that... hmmm...

Is there another class somewhere that just has an old-school unanimated progress bar?

kman
     
Clinically Insane
Join Date: Oct 2001
Location: San Diego, CA, USA
Status: Offline
Reply With Quote
Apr 9, 2003, 03:06 PM
 
A determinate progress bar shouldn't have a barbershop effect as far as I know.

EDIT: Yeah, yeah, I meant determinate.
(Last edited by Chuckit; Apr 9, 2003 at 03:42 PM. )
Chuck
___
"Instead of either 'multi-talented' or 'multitalented' use 'bisexual'."
     
Mac Elite
Join Date: Sep 2000
Location: Tempe, AZ
Status: Offline
Reply With Quote
Apr 9, 2003, 03:38 PM
 
A determinate progress bar should not show the barber pole effect. It does show a slight animation akin to moving bubbles. I don't know of any way to stop this - I believe that the OS spawns its own "heartbeat" thread that's responsible for animating this, but it shouldn't be taking much CPU.

The indeterminate progress bar is the one that shows the barber pole.
Geekspiff - generating spiffdiddlee software since before you began paying attention.
     
kman42  (op)
Professional Poster
Join Date: Sep 2000
Location: San Francisco
Status: Offline
Reply With Quote
Apr 9, 2003, 03:50 PM
 
Okay. I misspoke. They don't have the barbershop effect, they have 'waves' going from right to left. At any rate this effect takes about 6-10% of my CPU on an iBook 700. It's not that big of a deal except that the app is designed to monitor the progress of Folding@home and some people are reluctant to have any of their CPU cycles taken by a little animation in the progress bars. If I remove the progress bars, the app takes 0% cpu except when actually checking the status.

kman
     
Forum Regular
Join Date: Aug 2000
Location: UK
Status: Offline
Reply With Quote
Apr 9, 2003, 05:00 PM
 
Using class-dump I found these:

_stopAnimationWithWait:(char)fp12
setDisplayedWhenStopped:(char)fp12

I'll bet the arguments are just BOOLs.

There's also:

- (void)heartBeat:(struct ? *)fp12;

which you could probably override in a subclass to avoid using CPU.
     
Forum Regular
Join Date: May 2001
Location: Oviedo, Floriduh USA
Status: Offline
Reply With Quote
Apr 9, 2003, 09:01 PM
 
I haven't found a way to turn off the liquid effects, short of a system hack.

Thankfully, in Java, I can just change the look-and-feel to something less CPU-intensive.
folding@home is good for you.
     
   
Thread Tools
Forum Links
Forum Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Top
Privacy Policy
All times are GMT -5. The time now is 03:21 PM.
All contents of these forums © 1995-2011 MacNN. All rights reserved.
Branding + Design: www.gesamtbild.com
vBulletin v.3.8.7 © 2000-2011, Jelsoft Enterprises Ltd., Content Relevant URLs by vBSEO 3.3.2