Timer call not working


Good reading all this posts for troubleshooting. I am trying to develop a graphic application using Juce and I am running into a minor problem that I cannot figure out.
I use Timer as a parent for one of my Component classes but when the app is running timerCallback() is never called and paint() is called all the time instead even though I am not using repaint().
I used startTimer(whatever) and my own derived timerCallback() but to no avail.
Any ideas why this may be?

Thanks in advance,


From that description, you could be doing anything! I don’t know, but you’ll just have made a silly mistake somewhere. Timers are very well tested!


I don’t have a doubt about the timer class. The Juce library is very well thought out and works wonders.

I am just puzzle. Being new to programming I don’t really know where the application is running by default when not called by any user input and that prevents me from chasing down this mistake I must have done.

Could you hint me as to the main loop/cycle/thread workings?


Haven’t got time to explain all that here! Hit break and have a look at the threads if you want to see what’s going on, but basically it shouldn’t matter what’s going on under the hood.

Most likely you’ve not started the timer or haven’t written the correct callback (maybe mis-spelt it?)

I know it is hard to troubleshoot this one by messaging. I will keep trying to figure it out. Thanks.

I am stopping and stepping in all the time, but all I can see is that paint() is called constantly, timer is started and responds to isTimerRunning and getTimerInterval properly and my timerCallback() overriding the virtual call is there not receiving any call.

Thanks again. hopefully I will post some progress on what I am doing soon.

It would probably help if you posted the relevant code (the Timer and the child component).

yes I know, but I don’t knnow where is the code that is making this not working.
I started a new project with a simple Juce app and Timer works fine, so I am rebuilding my project around that so I get my project togoether again but with Timer working, but is going to take me all day probably.

Thanks anyway, I really appreciated the answers.