<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: BTimer Class: A Javascript Timer Class</title>
	<atom:link href="http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/</link>
	<description>The Adventures of a UCSB Computer Science Ph.D. Student</description>
	<lastBuildDate>Sat, 17 Jul 2010 00:07:24 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
	<item>
		<title>By: Bryce Boe</title>
		<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/comment-page-1/#comment-4740</link>
		<dc:creator>Bryce Boe</dc:creator>
		<pubDate>Wed, 01 Jul 2009 05:24:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/#comment-4740</guid>
		<description>Bob- My apologies for the late reply. I&#039;m sure by now you&#039;ve figured everything out about this code and perhaps made improvements or decided it&#039;s not very well written. It always fun to look at you own code from previous years. First I need to say I don&#039;t know javascript terribly well, definitely much less than I knew when I wrote this.

The self.ms in the setTimeout call is unnecessary and must have been an artifact of a previous version of this code. Regarding having multiple concurrent timers on a page, I seem to remember trying that and having a few problems.

The other functions are global functions because at the time I wrote pretty much everything as global functions unless they clearly should be in a class such as the timer code. Also I wanted to simply be able to call them from onclick events, but I now acknowledge that they needn&#039;t be global to do that.

Thanks for the comments.</description>
		<content:encoded><![CDATA[<p>Bob- My apologies for the late reply. I&#8217;m sure by now you&#8217;ve figured everything out about this code and perhaps made improvements or decided it&#8217;s not very well written. It always fun to look at you own code from previous years. First I need to say I don&#8217;t know javascript terribly well, definitely much less than I knew when I wrote this.</p>
<p>The self.ms in the setTimeout call is unnecessary and must have been an artifact of a previous version of this code. Regarding having multiple concurrent timers on a page, I seem to remember trying that and having a few problems.</p>
<p>The other functions are global functions because at the time I wrote pretty much everything as global functions unless they clearly should be in a class such as the timer code. Also I wanted to simply be able to call them from onclick events, but I now acknowledge that they needn&#8217;t be global to do that.</p>
<p>Thanks for the comments.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bob Gibson</title>
		<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/comment-page-1/#comment-4737</link>
		<dc:creator>Bob Gibson</dc:creator>
		<pubDate>Mon, 22 Jun 2009 02:45:26 +0000</pubDate>
		<guid isPermaLink="false">http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/#comment-4737</guid>
		<description>Why do you have the following as global functions?
--------------------------------------------------
function BTimerMyStart0()
function BTimerMyUpdate0()
function BTimerMyPause0()
function BTimerOther0( string )
--------------------------------------------------
This makes it that much harder to have multiple timers on a page.</description>
		<content:encoded><![CDATA[<p>Why do you have the following as global functions?<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
function BTimerMyStart0()<br />
function BTimerMyUpdate0()<br />
function BTimerMyPause0()<br />
function BTimerOther0( string )<br />
&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8212;&#8211;<br />
This makes it that much harder to have multiple timers on a page.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bob Gibson</title>
		<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/comment-page-1/#comment-4736</link>
		<dc:creator>Bob Gibson</dc:creator>
		<pubDate>Mon, 22 Jun 2009 02:24:36 +0000</pubDate>
		<guid isPermaLink="false">http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/#comment-4736</guid>
		<description>Interesting read.  I&#039;m still trying to digest it.

  Why does the setTimeout() call in your _run : function pass self.ms?  It appears to be unused.

  I&#039;m also trying to figure out to have multiple concurrent timers on one page, and don&#039;t know (yet) if this will resolve the issues that I have been having.

Thanks for sharing.
Bob</description>
		<content:encoded><![CDATA[<p>Interesting read.  I&#8217;m still trying to digest it.</p>
<p>  Why does the setTimeout() call in your _run : function pass self.ms?  It appears to be unused.</p>
<p>  I&#8217;m also trying to figure out to have multiple concurrent timers on one page, and don&#8217;t know (yet) if this will resolve the issues that I have been having.</p>
<p>Thanks for sharing.<br />
Bob</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bryce Boe</title>
		<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/comment-page-1/#comment-3009</link>
		<dc:creator>Bryce Boe</dc:creator>
		<pubDate>Mon, 09 Jun 2008 18:24:34 +0000</pubDate>
		<guid isPermaLink="false">http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/#comment-3009</guid>
		<description>You can use onclick events to update the interval by 20 seconds for each click, however it wont update the currently running timer. To get around that I&#039;d suggest using a 1 second timer, with a pseudo update function which keeps track of the number of times it&#039;s been called. When the count reaches a certain value, the desired interval, call the real function. Then to increase the interval by 20 increase the value that the pseudo update function uses.

Hopefully that helps.</description>
		<content:encoded><![CDATA[<p>You can use onclick events to update the interval by 20 seconds for each click, however it wont update the currently running timer. To get around that I&#8217;d suggest using a 1 second timer, with a pseudo update function which keeps track of the number of times it&#8217;s been called. When the count reaches a certain value, the desired interval, call the real function. Then to increase the interval by 20 increase the value that the pseudo update function uses.</p>
<p>Hopefully that helps.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sourav Das</title>
		<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/comment-page-1/#comment-3008</link>
		<dc:creator>Sourav Das</dc:creator>
		<pubDate>Mon, 09 Jun 2008 11:12:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/#comment-3008</guid>
		<description>how to add 20 seconds with timer by every click in javascript</description>
		<content:encoded><![CDATA[<p>how to add 20 seconds with timer by every click in javascript</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Bryce Boe</title>
		<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/comment-page-1/#comment-660</link>
		<dc:creator>Bryce Boe</dc:creator>
		<pubDate>Thu, 12 Apr 2007 16:55:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/#comment-660</guid>
		<description>This does look pretty clean unfortunately ASP.NET is not a choice for me. Also in viewing the source created by the timer page this appears:

Control._defaultUrl=&#039;http://ajaxwidgets.com/AllControlsSamples/Timer.aspx&#039;;
Control.registerControl(new WebControl.LinkButton(&#039;ctl00_showCode&#039;)).observe(&#039;click&#039;);Control.registerControl(new WebControl.Button(&#039;ctl00_ContentPlaceHolder1_Button1&#039;)).observe(&#039;click&#039;);Control.registerControl(new WebControl.Label(&#039;ctl00_ContentPlaceHolder1_Label2&#039;));Control.registerControl(new WebControl.Label(&#039;ctl00_ContentPlaceHolder1_Label1&#039;));Control.registerControl(new Control.Timer(&#039;ctl00_ContentPlaceHolder1_Timer1&#039;, {enabled:true, milliseconds:1000})); 

Though I haven&#039;t actually taken the time to figure out how exactly the Gaia stuff works it seems the only flaw between our two timers is that Microsoft unfortunately doesn&#039;t fully support Javascript; I suppose that makes BTimer inferior to GAIA although BTimer doesn&#039;t require server side scripting, which I&#039;m guessing GAIA does.</description>
		<content:encoded><![CDATA[<p>This does look pretty clean unfortunately ASP.NET is not a choice for me. Also in viewing the source created by the timer page this appears:</p>
<p>Control._defaultUrl=&#8217;http://ajaxwidgets.com/AllControlsSamples/Timer.aspx&#8217;;<br />
Control.registerControl(new WebControl.LinkButton(&#8216;ctl00_showCode&#8217;)).observe(&#8216;click&#8217;);Control.registerControl(new WebControl.Button(&#8216;ctl00_ContentPlaceHolder1_Button1&#8242;)).observe(&#8216;click&#8217;);Control.registerControl(new WebControl.Label(&#8216;ctl00_ContentPlaceHolder1_Label2&#8242;));Control.registerControl(new WebControl.Label(&#8216;ctl00_ContentPlaceHolder1_Label1&#8242;));Control.registerControl(new Control.Timer(&#8216;ctl00_ContentPlaceHolder1_Timer1&#8242;, {enabled:true, milliseconds:1000})); </p>
<p>Though I haven&#8217;t actually taken the time to figure out how exactly the Gaia stuff works it seems the only flaw between our two timers is that Microsoft unfortunately doesn&#8217;t fully support Javascript; I suppose that makes BTimer inferior to GAIA although BTimer doesn&#8217;t require server side scripting, which I&#8217;m guessing GAIA does.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Thomas Hansen</title>
		<link>http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/comment-page-1/#comment-657</link>
		<dc:creator>Thomas Hansen</dc:creator>
		<pubDate>Thu, 12 Apr 2007 13:21:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.bryceboe.com/2007/04/11/btimer-class-a-javascript-timer-class/#comment-657</guid>
		<description>If you&#039;re using ASP.NET you would rather want to check out:
http://ajaxwidgets.com/AllControlsSamples/Timer.aspx

:)

.t</description>
		<content:encoded><![CDATA[<p>If you&#8217;re using ASP.NET you would rather want to check out:<br />
<a href="http://ajaxwidgets.com/AllControlsSamples/Timer.aspx" rel="nofollow">http://ajaxwidgets.com/AllControlsSamples/Timer.aspx</a></p>
<p> <img src='http://www.bryceboe.com/wordpress/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>.t</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Dynamic Page Served (once) in 0.397 seconds -->
