Well my app seems to be working fine now but as I look in Activity Monitor I see that my app is taking .2 % of cpu time and has 3 threads using 8.81 MB of ram.
Now this is not bad but it looks like it could be much better.
My app is a very small one. It does almost nothing most of the time except checking a url for a certain piece of data every time through the idle handler. The idle handler return value is set by the user in the preferences window which is one of three windows the app has. Most of the time these window are not shown on screen until the idle handler finds the data it’s looking for at the url it checks each time through. This window that opens when the data is found has a button that opens the third window for viewing the data. So most of the times these windows are closed but I’m assuming by the coincidence of seeing 3 threads in activity viewer that maybe each window is occupying a thread wether it is on screen or not. Could that be the case?
If so How can I get those threads to go away when the windows aren’t on screen?
Also is the idles handler the best way to do that or would it be better to put the app to sleep for that amount of time in between checking for the data?
As you can already tell by what you’ve read so far I’m pretty lost here. Any and all help offered will be greatly appreciated.