This week's book giveaway is in the Mac OS forum. We're giving away four copies of a choice of "Take Control of Upgrading to Yosemite" or "Take Control of Automating Your Mac" and have Joe Kissell on-line! See this thread for details.
I'm creating an application that will act as a Stopwatch. It will have a card layout with three cards. The first will be a clock, the second will be a stopwatch, and the third will be a timer that counts backwards until reaching 0. Can someone please give me a little advise with regards to the threads? At first I was thinking about creating a different thread for each of the cards (3 timers). Now I'm thinking about creating one swing timer in a swingworker object, and using the invokeLater method to update all three cards. Does that sound like a good idea, or am I way off?
seems like the easiest thing to do would be to just use a single thread of your own creation(not the one created by the window). You could set your run method to execute every second(or maybe half second to be sure you get time changes closer to the actual time tic). Inside the run method call the update for each of your time displays(time,count up,count down). Each time display would need to check itself for invalid values (like less than zero for the count down). Something along those lines is how I would do it. Hope this helps.