Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!


Click here to return to the '10.4: Cut down on the World Clock widget's CPU usage' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.4: Cut down on the World Clock widget's CPU usage
Authored by: pete.boardman on Jun 13, '05 03:10:16PM

I also wanted to reduce cpu usage of this clock, since I'm running two or three of them on the desktop rather than in Dashboard. But I found I didn't need to switch off seconds altogether - I just removed the 'sproing' animation effect - which is cool and neat, but unnecessary. Before edits, the World Clock used 10% CPU; with edits, but still with seconds and a digital clock, I've got it down to 1.8%.

(

But the main modification I made was to convert to 24 hour analog operation. More here. :-)

The only problem is wondering what changes Apple make to the original when they issue a new version...



[ Reply to This | # ]
10.4: Cut down on the World Clock widget's CPU usage
Authored by: locklin on Jun 13, '05 09:22:05PM

Hey Pete,

How do you remove just the 'sproing' efect?



[ Reply to This | # ]
10.4: Cut down on the World Clock widget's CPU usage
Authored by: CraigStanton on Jun 14, '05 06:32:20AM

From my original hint:

Now change this line to stop it from calculating the sway of the second hand.
<code> timerInterval = setInterval("updateTime(true);", 1000);</code>
to
<code> timerInterval = setInterval("updateTime(false);", 1000);</code>



[ Reply to This | # ]
10.4: Cut down on the World Clock widget's CPU usage
Authored by: Jeff Fork on Mar 13, '08 03:31:12PM

obviously, yes, i know the post i am replying to is almost 2 years old, but i had the same question, so this might help someone.

also, the "no seconds" fix does not work in 10.5 as the "true" string does not exist.

to remove the "sproing" animation only, i found this:
find "sproing" in the WorldClock.js
find the line:

var secondsSweepbackMax = 0.15;

change to:

var secondsSweepbackMax = 0;

worked for me, hope this helps!



[ Reply to This | # ]