Closed Thread Icon

Preserved Topic: Tracking called functions... (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=18083" title="Pages that link to Preserved Topic: Tracking called functions... (Page 1 of 1)" rel="nofollow" >Preserved Topic: Tracking called functions... <span class="small">(Page 1 of 1)</span>\

 
jiblet
Paranoid (IV) Inmate

From: Minneapolis, MN, USA
Insane since: May 2000

posted posted 06-06-2001 21:50

I am thinking about trying to clean up this messy rollover script I created about a year ago.
http://www.coffman.umn.edu/insider/

It is a crazy hack I built from Doc's rollover script, but it has very annoying behaviour when you move over the rollovers too fast. I've done a lot of programming since then, and so I feel like it's time to clean it up. I'm going to condense all the rollover functions to one function, then add some functionality that will cancel the current rollover effect and reset the graphics when a new rollover is activated. The only problem is I will need 2 things:

A) A way to stop running an existing instance of the method.
B) A way to reset the graphics that had been effected.

Anyone have any insight to share about this type of problem?

-jiblet

mr.maX
Maniac (V) Mad Scientist

From: Belgrade, Serbia
Insane since: Sep 2000

posted posted 06-06-2001 22:21

When using timers, you should assign some variable to them:

var maxTimer;
maxTimer = setTimeout(cmd,10);

And then use clearTimeout() function to stop them:

clearTimeout(maxTimer);

After you stop them simply restore your images to their originals and then start new timer(s)...

jiblet
Paranoid (IV) Inmate

From: Minneapolis, MN, USA
Insane since: May 2000

posted posted 06-06-2001 23:07

damn u know every language thanks for helping me out for the 100th time.

-jiblet

« BackwardsOnwards »

Show Forum Drop Down Menu