圣诞老人时间:是:浏览器的时间准确性 [英] Santa Time : was: Time accuracy in browser

查看:75
本文介绍了圣诞老人时间:是:浏览器的时间准确性的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

关于浏览器中时间精度的侧面话题

< http://groups.google.com/group/comp.lang.javascript/browse_frm/thread/91b9f3fd90513161/1ea06131c63cfdf0? hl = zh_cn#doc_620f160f0cb57c8c>

声明:

至少Internet Explorer并不是真实的脚本中的时间

方法。相反,它提供脚本方法应用程序滴答。

预定义的毫秒数。如果请求的时间范围

符合偶数的滴答,那么脚本将更接近

实时流量。如果请求的时间框架不适合甚至

的额外费用,那么将使用最接近的数量的刻度。

因此结果脚本将落后或者在每个循环中相对于

实时向前冲。


实验:

复制并粘贴底部的代码

此页面也可以在

< http://www.geocities.com/schools_ring/SantaTime.html>

$ b找到$ b红色圣诞老人和蓝色圣诞老人每30ms移动一次

红色圣诞老人(顶部)正在使用TRUESPEED接口移动 - 唯一的

接口到实际系统时间我到目前为止已经找到了。

蓝色圣诞老人(底部)正在移动没有TRUESPEED接口,因此它的延迟时间为最接近的应用程序勾号。这是

大于30ms


预期结果:

尽管设置了相同的时间延迟,Blue Santa将落后。 br />

结果:

按预期


PS我有足够的圣诞老人和雪人来解决任何问题:-)


P.P.S因为专有< marquee>标签此测试必须在

Internet Explorer 4.x或更高版本下运行。

< html>

< head>

< title>圣诞老人的时间< / title>

< meta http-equiv =" Content-Type" content =" text / html;

charset = iso-8859-1">

< script type =" text / javascript">


var Santa =''#define Santa_width 128 \ n #define Santa_height 128 \ nstatic

char Santa_bits [] = {\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00,0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00,0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00,0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00,0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00,0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00,0x 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0x01,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0x01,0x00,0x00,0xEC,0x01,

0x00,0x00, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0x01,0x00,0x00,0x60,0x03,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0x01,0x00,0x00,0x25,0x0F,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0x04,0x00,0x00,0x15,0x11,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x10,0x00,0x00,0x1F,0x02,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x00,0x3C,0x7E,0x43,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x83,0x1F,0x80,0x83,

0x07,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0x0F,0xE0,0x83,

0x1C,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0x07,0x90,0xC5,

0x20,0x00, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x07,0x5F,0x7E,

0x40,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x07,0x04,0x0C,

0x80,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x83,0x42,0x0C,

0x00,0x01, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x83,0x81,0xFA,

0x00,0x02, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0xC0,0x81,0x81,0x41,

0x01,0x0E, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0xDF,0x41,0x08,0x43,

0x02,0x3E, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x1C,0xFC,0x41,0x00,0x64,

0x06,0x7E, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x21,0x00,0x3C,

0x04,0xFF, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x20,0x80,0x07,

0x04,0xFF, 0x01,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0xE0,0x80,0x03,

0x86,0xFF, 0x01,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x00,0xE0,0x3F,0x00,

0xC6,0xFF, 0x03,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0xCF,0x00,0xF8,

0xFF,0xFF, 0x07,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0xF0,0x87,0x01,0xE4,

0xF1,0xFF, 0x07,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0xFF,0x77,

0xE0,0xFF, 0x0F,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x01,0x00,0x00,0xFE,0x73,

0xE0,0xFF, 0x0F,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0xF0,0x63,

0xC0,0xFF, 0X 0F,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x02,0x00,0x00,0x00,0x00,

0xC0,0xFF, 0x0F,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0x00,0x00,0x00,0x00,

0xC0,0xFF, 0x1F,0x00,\

0x00,0x00,0x00,0x00,0x00,0x0F,0x00,0x18,0x00,0x00,0x00,0x00,

0xC0,0xFF, 0x1F,0x00,\

0x00,0x00,0x00,0x00,0xC0,0xFF,0x01,0x18,0x00,0x00,0x00,0x00,

0xC0,0xFF, 0x1F,0x00,\

0x00,0x00,0x00,0x00,0x38,0x00,0x06,0x38,0x00,0x00,0x00,0x00,

0xC0,0xFF, 0x1F,0x00,\

0x00,0x00,0x00,0x00,0x0E,0xC0,0x3F,0xFF,0x00,0x00,0x00,0x00,

0xC0,0xFF, 0x1F,0x00,\

0x00,0x00,0x00,0x00,0x07,0xFC,0xFF,0xFE,0x01,0x00,0x00,0x00,

0xC0,0xFF, 0x1F,0x00,\

0x00,0x00,0x00,0x80,0x01,0xFF,0xFF,0xFF,0x07,0x00,0x00,0x00,

0xC0,0xFF, 0X 0F,0x00,\

0x00,0x00,0x00,0x80,0xC0,0xFF,0x3F,0xFF,0x1F,0x00,0x00,0x00,

0xE0,0xFF, 0x0F,0x00,\

0x00,0x00,0x00,0xC0,0xC0,0xFF,0x1F,0xFF,0x7F,0x00,0x00,0x00,

0xE0,0xFF, 0x0F,0x00,\

0x00,0x00,0x70,0xE0,0xE0,0xFF,0x9F,0xFF,0xFF,0x00,0x00,0x00,

0xF0,0xFF, 0x07,0x00,\

0x00,0x00,0x70,0x60,0xE0,0xFF,0x8F,0xFF,0xFF,0x1F,0x00,0x00,

0xF8,0xFF, 0x07,0x00,\

0x00,0x00,0x10,0x30,0xF0,0xFF,0x8F,0xFF,0xFF,0xFF,0x00,0x00,

0xFC,0xFF, 0x03,0x00,\

0x00,0xE0,0x91,0x10,0xF0,0xFF,0x87,0xFF,0xFF,0xFF,0x1F,0xC0,

0xFF,0xFF, 0x00,0x00,\

0x00,0xFC,0x1F,0x10,0xF0,0xFF,0x87,0xFF,0xFF,0xFF,0xFF,0xFF,

0xFF,0x7F, 0x00,0x00,\

0x00,0x0C,0x00,0x11,0xF0,0xFF,0x87,0xFF,0xFF,0xFF,0xFF,0xFF,

0xFF,0x1F, 0X 00,0x00,\

0x00,0x06,0x00,0x10,0xF0,0xFF,0x83,0xFF,0xFF,0xFF,0xFF,0xFF,

0xFF,0x01, 0x00,0x00,\

0x00,0x42,0x00,0x1A,0xF0,0xFF,0x83,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x00,0x00,\

0x00,0xFE,0x00,0x0A,0xF0,0xFF,0x83,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x00,0x00,\

0x00,0x80,0x01,0x08,0xF0,0xFF,0x83,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x00,0x00,\

0x00,0x80,0x01,0x0C,0xF0,0xFF,0x03,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x00,0x00,\

0x00,0x00,0x01,0x08,0xF0,0xFF,0x03,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x00,0x00,\

0x00,0x00,0x03,0x08,0xF0,0xFF,0x03,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x00,0x00,\

0x00,0x00,0x03,0x08,0xF0,0xFF,0x03,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0X 00,0x00,\

0x00,0x00,0x03,0x08,0xF0,0xFF,0x03,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x20,0x00,\

0x00,0x00,0x06,0x18,0xF0,0xFF,0x07,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0x00, 0x60,0x00,\

0x00,0x00,0x04,0x10,0xE0,0xFF,0x07,0xFF,0xFF,0xFF,0xFF,0xFF,

0x07,0xE0, 0xE3,0x00,\

0x00,0x00,0x04,0x10,0xE0,0xFF,0x07,0xFE,0xFF,0xFF,0xFF,0xFF,

0x83,0x3F, 0xF7,0x01,\

0x00,0x00,0xE4,0x1F,0xE0,0xFF,0x0F,0xFE,0xFF,0xFF,0xFF,0xDF,

0xC3,0xF1, 0xF7,0x00,\

0x00,0x00,0xFC,0x3F,0xE0,0xFF,0x0F,0xFC,0xFF,0xFF,0xFF,0xBF,

0x41,0xF0, 0x7F,0x00,\

0x00,0x00,0xFC,0x3F,0xC0,0xFF,0x0F,0xF8,0xFF,0xFF,0xFF,0x3F,

0xA1,0xE8, 0x7F,0x00,\

0x00,0x00,0xFC,0x3F,0xC0,0xFF,0x1F,0xF8,0xFF,0xFF,0xFF,0x3F,

0xA2,0xAD, 0X 3F,0x00,\

0x00,0x00,0xFE,0x7F,0xC0,0xFF,0x1F,0xF0,0xFF,0xFF,0xFF,0x3F,

0x04,0x26, 0xFF,0x03,\

0x00,0x00,0xFE,0x7F,0xC0,0xFF,0x3F,0xF0,0xFF,0xFF,0xFF,0x7F,

0x18,0x24, 0xFF,0x07,\

0x00,0x00,0xFE,0xFF,0x80,0xFF,0x7F,0xE0,0xFF,0xFF,0xFF,0x7F,

0x90,0xB3, 0xEF,0x07,\

0x00,0x00,0xFE,0xFF,0x80,0xFF,0x7F,0xC0,0xFF,0xFF,0xFF,0x7F,

0xE0,0xF3, 0xDF,0x05,\

0x00,0x00,0xFE,0xFF,0x00,0xFF,0xFF,0x80,0xFF,0xFF,0xFF,0x3F,

0x20,0x68, 0x3E,0x18,\

0x00,0x00,0xFE,0xFF,0x01,0xFE,0xFF,0x01,0xFF,0xFF,0xFF,0x1F,

0x20,0x64, 0x6C,0x30,\

0x00,0x00,0xFC,0xFF,0x01,0xFC,0xFF,0x03,0xFC,0xFF,0xF9,0x0F,

0x20,0xF4, 0xC0,0x20,\

0x00,0x00,0xFC,0xFF,0x03,0xF8,0xFF,0x03,0xF0,0xFF,0xF0,0x07,

0x20,0xB4, 0X 81,0x41,\

0x00,0x00,0xF8,0xFF,0x07,0xF0,0xFF,0x0F,0xE0,0x7F,0x3C,0x00,

0x20,0xB4, 0x83,0xC3,\

0x00,0x00,0xF0,0xFF,0x0F,0xE0,0xFF,0x1F,0x00,0x7E,0xEC,0x00,

0x20,0x1C, 0x06,0xFF,\

0x00,0x00,0xC0,0xFF,0x1F,0x80,0xFF,0x3F,0x00,0x70,0xD6,0x01,

0x30,0x18, 0x84,0x87,\

0x00,0x00,0x80,0xFF,0x3F,0x00,0xFF,0xFF,0x00,0x30,0x42,0x07,

0x18,0x18, 0xF8,0x82,\

0x00,0x00,0x00,0xFE,0x3F,0x00,0xFC,0xFF,0x03,0x30,0x6E,0xFE,

0x1F,0x18, 0x10,0x42,\

0x00,0x00,0x00,0xFC,0x7F,0x00,0xF8,0xFF,0x1F,0x38,0x67,0xF8,

0x7F,0x11, 0x18,0x42,\

0x00,0x00,0x00,0xE0,0xFF,0x00,0xF0,0xFF,0xFF,0x1F,0x70,0x00,

0xC0,0x11, 0x18,0x43,\

0x00,0x00,0x00,0x80,0xFF,0x01,0xC0,0xFF,0xFF,0x1F,0x5E,0x00,

0x00,0x32, 0X 18,0x43,\

0x00,0x00,0x00,0x00,0xFF,0x07,0x80,0xFF,0xFF,0x8F,0x4F,0x00,

0x00,0x6C, 0x08,0x21,\

0x00,0x00,0x00,0x00,0xF0,0x0F,0x00,0xFC,0xFF,0xFF,0x67,0x00,

0x00,0x7C, 0x08,0x21,\

0x00,0x00,0x00,0x00,0xC0,0x1F,0x00,0xE0,0xFF,0xFF,0x23,0x00,

0x00,0x80, 0x8C,0x3F,\

0x00,0x00,0x00,0x00,0x00,0x7E,0x00,0x80,0xFF,0xFF,0x11,0x00,

0x00,0x80, 0x85,0x0F,\

0x00,0x00,0x00,0x00,0x00,0xF8,0x00,0x00,0xFC,0x3F,0x18,0x00,

0x00,0x00, 0x7F,0x00,\

0x00,0x00,0x00,0x00,0x00,0xF0,0x07,0x00,0x00,0x00,0x08,0x00,

0x00,0x00, 0x06,0x00,\

0x00,0x00,0x00,0x00,0x00,0xE0,0x1F,0x00,0x00,0x00,0x04,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x7F,0x00,0x00,0x00,0x03,0x00,

0x00,0x00, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xFC,0x0F,0x00,0xC0,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0xFF,0x01,0x38,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xF0,0xFF,0xFF,0x07,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0xFF,0xFF,0x03,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x80,0xFF,0xFF,0x03,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFF,0xFF,0x07,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFE,0xFF,0x07,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xFC,0xFF,0x03,0x00,0x00,

0x00,0x00, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xF8,0xFF,0x03,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x20,0x00,0x04,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x60,0x00,0x04,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xC0,0x00,0x88,0x01,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x00,0x48,0x03,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x80,0x01,0x30,0x03,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x03,0x00,0x03,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x06,0x80,0x01,0x00,

0x00,0x00, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x04,0xC0,0x01,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x0C,0xFF,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xD8,0x3F,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x90,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xB0,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0xE0,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0X 00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,0x00,

0x00,0x00, 0x00,0x00,\

}; \ n'';


< / script>


< style type =" text / css">

body {

background-color:#FFFFFF

}

span {

身高:128px;

宽度:128px;

}

#Santa01 {

filter:progid:DXImageTransform.Microsoft.dropShadow(

Color =#FF0000,offX = 2,offY = 0,positive = true);

}

#Santa02 {

filter:progid:DXImageTransform.Microsoft.dropShadow(

Color =#0000FF,offX = 2, offY = 0,positive = true);

}

< / style>


< / head>


< body bgcolor =" #FFFFFFF">


< marquee direc灰= QUOT;右" behavior =" scroll"

scrollamount =" 5" scrolldelay =" 30"

TRUESPEED>< span id =" Santa01">< img

src =" javascript :Santa"

width =" 128"高度= QUOT; 128" VSPACE =" 0" hspace =" 0"

border =" 0">< / span>< / marquee>


< marquee direction ="右" behavior =" scroll"

scrollamount =" 5" scrolldelay =" 30"

Following the side thread about the time precision in browser at
<http://groups.google.com/group/comp.lang.javascript/browse_frm/thread/91b9f3fd90513161/1ea06131c63cfdf0?hl=en#doc_620f160f0cb57c8c>
Statement:
At the very least Internet Explorer doesn''t go by "real" time in script
methods. Instead it provides to script methods "application ticks" with
predefined amount of milliseconds in them. If the requested time frame
fits into an even amount of ticks then the script goes closer to the
real time flow. If the requested time frame doesn''t fit into an even
amount of ticks then the closest even amoount of ticks is used instead.
As the result script will fall behind or rush forward relative to the
real time on each loop.

Experiment:
copy and paste code at the bottom
also this page can be found at
<http://www.geocities.com/schools_ring/SantaTime.html>

Both Red Santa and Blue Santa are set to move each 30ms
Red Santa (top) is moving using TRUESPEED interface - the only
interface to the real system time I''ve found so far.
Blue Santa (bottom) is moving w/o TRUESPEED interface, therefore its
30ms delay gets rounded to the closest "application tick" which is
bigger than 30ms

Expected Results:
Despite the same time delay set, Blue Santa will fall behind.

Results:
As expected

P.S. I have enough Santas and Snowmen for any further questions :-)

P.P.S Because of proprietary <marquee> tag this test must be run under
Internet Explorer 4.x or higher.
<html>
<head>
<title>Santa''s Time</title>
<meta http-equiv="Content-Type" content="text/html;
charset=iso-8859-1">
<script type="text/javascript">

var Santa = ''#define Santa_width 128\n#define Santa_height 128\nstatic
char Santa_bits[] = {\
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0x01, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x01, 0x00, 0x00, 0xEC, 0x01,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x01, 0x00, 0x00, 0x60, 0x03,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x01, 0x00, 0x00, 0x25, 0x0F,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0x04, 0x00, 0x00, 0x15, 0x11,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10, 0x00, 0x00, 0x1F, 0x02,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x3C, 0x7E, 0x43,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x83, 0x1F, 0x80, 0x83,
0x07, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0x0F, 0xE0, 0x83,
0x1C, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x07, 0x90, 0xC5,
0x20, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x07, 0x5F, 0x7E,
0x40, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x07, 0x04, 0x0C,
0x80, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x83, 0x42, 0x0C,
0x00, 0x01, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x83, 0x81, 0xFA,
0x00, 0x02, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0xC0, 0x81, 0x81, 0x41,
0x01, 0x0E, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xDF, 0x41, 0x08, 0x43,
0x02, 0x3E, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x1C, 0xFC, 0x41, 0x00, 0x64,
0x06, 0x7E, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x21, 0x00, 0x3C,
0x04, 0xFF, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x20, 0x80, 0x07,
0x04, 0xFF, 0x01, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0xE0, 0x80, 0x03,
0x86, 0xFF, 0x01, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x00, 0xE0, 0x3F, 0x00,
0xC6, 0xFF, 0x03, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xCF, 0x00, 0xF8,
0xFF, 0xFF, 0x07, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0xF0, 0x87, 0x01, 0xE4,
0xF1, 0xFF, 0x07, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0xFF, 0x77,
0xE0, 0xFF, 0x0F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x00, 0x00, 0xFE, 0x73,
0xE0, 0xFF, 0x0F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0xF0, 0x63,
0xC0, 0xFF, 0x0F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x02, 0x00, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x0F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0x00, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x1F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x0F, 0x00, 0x18, 0x00, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x1F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0xC0, 0xFF, 0x01, 0x18, 0x00, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x1F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x38, 0x00, 0x06, 0x38, 0x00, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x1F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x0E, 0xC0, 0x3F, 0xFF, 0x00, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x1F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x07, 0xFC, 0xFF, 0xFE, 0x01, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x1F, 0x00, \
0x00, 0x00, 0x00, 0x80, 0x01, 0xFF, 0xFF, 0xFF, 0x07, 0x00, 0x00, 0x00,
0xC0, 0xFF, 0x0F, 0x00, \
0x00, 0x00, 0x00, 0x80, 0xC0, 0xFF, 0x3F, 0xFF, 0x1F, 0x00, 0x00, 0x00,
0xE0, 0xFF, 0x0F, 0x00, \
0x00, 0x00, 0x00, 0xC0, 0xC0, 0xFF, 0x1F, 0xFF, 0x7F, 0x00, 0x00, 0x00,
0xE0, 0xFF, 0x0F, 0x00, \
0x00, 0x00, 0x70, 0xE0, 0xE0, 0xFF, 0x9F, 0xFF, 0xFF, 0x00, 0x00, 0x00,
0xF0, 0xFF, 0x07, 0x00, \
0x00, 0x00, 0x70, 0x60, 0xE0, 0xFF, 0x8F, 0xFF, 0xFF, 0x1F, 0x00, 0x00,
0xF8, 0xFF, 0x07, 0x00, \
0x00, 0x00, 0x10, 0x30, 0xF0, 0xFF, 0x8F, 0xFF, 0xFF, 0xFF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00,
0xC0, 0x11, 0x18, 0x43, \
0x00, 0x00, 0x00, 0x80, 0xFF, 0x01, 0xC0, 0xFF, 0xFF, 0x1F, 0x5E, 0x00,
0x00, 0x32, 0x18, 0x43, \
0x00, 0x00, 0x00, 0x00, 0xFF, 0x07, 0x80, 0xFF, 0xFF, 0x8F, 0x4F, 0x00,
0x00, 0x6C, 0x08, 0x21, \
0x00, 0x00, 0x00, 0x00, 0xF0, 0x0F, 0x00, 0xFC, 0xFF, 0xFF, 0x67, 0x00,
0x00, 0x7C, 0x08, 0x21, \
0x00, 0x00, 0x00, 0x00, 0xC0, 0x1F, 0x00, 0xE0, 0xFF, 0xFF, 0x23, 0x00,
0x00, 0x80, 0x8C, 0x3F, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x7E, 0x00, 0x80, 0xFF, 0xFF, 0x11, 0x00,
0x00, 0x80, 0x85, 0x0F, \
0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0x00, 0x00, 0xFC, 0x3F, 0x18, 0x00,
0x00, 0x00, 0x7F, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0x07, 0x00, 0x00, 0x00, 0x08, 0x00,
0x00, 0x00, 0x06, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x1F, 0x00, 0x00, 0x00, 0x04, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7F, 0x00, 0x00, 0x00, 0x03, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFC, 0x0F, 0x00, 0xC0, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0x01, 0x38, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF0, 0xFF, 0xFF, 0x07, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0xFF, 0xFF, 0x03, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0xFF, 0xFF, 0x03, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, 0xFF, 0x07, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFE, 0xFF, 0x07, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFC, 0xFF, 0x03, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xF8, 0xFF, 0x03, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x20, 0x00, 0x04, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x60, 0x00, 0x04, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xC0, 0x00, 0x88, 0x01, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x00, 0x48, 0x03, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x80, 0x01, 0x30, 0x03, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x03, 0x00, 0x03, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x06, 0x80, 0x01, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x04, 0xC0, 0x01, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x0C, 0xFF, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xD8, 0x3F, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x90, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xB0, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xE0, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
0x00, 0x00, 0x00, 0x00, \
};\n'';

</script>

<style type="text/css">
body {
background-color: #FFFFFF
}
span {
height: 128px;
width: 128px;
}
#Santa01 {
filter: progid:DXImageTransform.Microsoft.dropShadow(
Color=#FF0000,offX=2,offY=0,positive=true);
}
#Santa02 {
filter: progid:DXImageTransform.Microsoft.dropShadow(
Color=#0000FF,offX=2,offY=0,positive=true);
}
</style>

</head>

<body bgcolor="#FFFFFF">

<marquee direction="right" behavior="scroll"
scrollamount="5" scrolldelay="30"
TRUESPEED><span id="Santa01"><img
src="javascript:Santa"
width="128" height="128" vspace="0" hspace="0"
border="0"></span></marquee>

<marquee direction="right" behavior="scroll"
scrollamount="5" scrolldelay="30"

< span id =" Santa02">< img
<span id="Santa02"><img



src =" javascript :Santa"

width =" 128"高度= QUOT; 128" VSPACE =" 0" hspace =" 0"

border =" 0">< / span>< / marquee>


< / body>

< / html>


src="javascript:Santa"
width="128" height="128" vspace="0" hspace="0"
border="0"></span></marquee>

</body>
</html>

推荐答案

谷歌通过解析和扭曲发布的代码似乎有了新的爱好。

以下是测试用例的压缩变体:


< http://www.geocities.com/schools_ring/SantaTime.zip>

Google seems to have a new hobby by parsing and twisting posted code.
Here is the zipped variant of the testcase:

<http://www.geocities.com/schools_ring/SantaTime.zip>


VK在12/4/2005 1:40 PM说了以下内容:
VK said the following on 12/4/2005 1:40 PM:
关于浏览器中时间精度的侧面线程在
< http://groups.google.com/group/comp.lang.javascript/browse_frm/thread/91b9f3fd90513161/1ea06131c63cfdf0?hl = zh_cn#doc_620f160f0cb57c8c>

声明:<至少Internet Explorer并没有通过真实的方式。时间用脚本
方法。相反,它提供脚本方法应用程序滴答。
预定义的毫秒数。如果请求的时间框架符合偶数量的刻度,则脚本更接近实时流程。如果请求的时间范围不适合甚至数量的刻度线,那么将使用最接近的刻度线。
因为结果脚本将落后或相对于每个循环上的实时。

实验:
复制并粘贴底部的代码


复制时无法正常工作/粘贴。

此页面也可以在
< http://www.geocities.com/schools_ring/SantaTime.html>

这两个红色找到圣诞老人和蓝色圣诞老人每30ms移动一次
红色圣诞老人(顶部)正在使用TRUESPEED接口移动 - 这是我到目前为止找到的真实系统时间的唯一接口。


TRUESPEED是IE-ism,不受Mozilla的尊重。

Blue Santa(底部)正在移动没有TRUESPEED接口,因此它的
30ms延迟四舍五入到最接近的应用程序滴答。
大于30ms


您应该在其他浏览器中进行测试并查看结果。

预期结果:
尽管延迟时间相同,Blue Santa也会落后。


我只买两个黑色圣诞老人但是他们以相同的速度移动。

结果:
正如预期的那样

PS我有足够的圣诞老人和雪人进一步提问:-)

P.P.S因为专有< marquee>标签此测试必须在Internet Explorer 4.x或更高版本下运行。
Following the side thread about the time precision in browser at
<http://groups.google.com/group/comp.lang.javascript/browse_frm/thread/91b9f3fd90513161/1ea06131c63cfdf0?hl=en#doc_620f160f0cb57c8c>
Statement:
At the very least Internet Explorer doesn''t go by "real" time in script
methods. Instead it provides to script methods "application ticks" with
predefined amount of milliseconds in them. If the requested time frame
fits into an even amount of ticks then the script goes closer to the
real time flow. If the requested time frame doesn''t fit into an even
amount of ticks then the closest even amoount of ticks is used instead.
As the result script will fall behind or rush forward relative to the
real time on each loop.

Experiment:
copy and paste code at the bottom
It doesn''t work properly when copy/pasted.
also this page can be found at
<http://www.geocities.com/schools_ring/SantaTime.html>

Both Red Santa and Blue Santa are set to move each 30ms
Red Santa (top) is moving using TRUESPEED interface - the only
interface to the real system time I''ve found so far.
The TRUESPEED is an IE-ism that is not honored by Mozilla.
Blue Santa (bottom) is moving w/o TRUESPEED interface, therefore its
30ms delay gets rounded to the closest "application tick" which is
bigger than 30ms
You should test it in some other browser and see what the results are.
Expected Results:
Despite the same time delay set, Blue Santa will fall behind.
I only get two black santas but they move at the same speed.
Results:
As expected

P.S. I have enough Santas and Snowmen for any further questions :-)

P.P.S Because of proprietary <marquee> tag this test must be run under
Internet Explorer 4.x or higher.




您应该在说明

那个。它不是marquee标签本身,而是

TRUESPEED的IE-only属性导致它不能在非IE浏览器中执行您想要的操作。


-

兰迪

comp.lang.javascript常见问题 - http://jibbering.com/faq &新闻组每周

Javascript最佳实践 - http://www.JavascriptToolbox .com / bestpractices /



You should test the marquee tag in some other browsers before stating
that. It is not the marquee tag itself but the IE-only attribute of
TRUESPEED that causes it not to do what you want it to do in non-IE
browsers.

--
Randy
comp.lang.javascript FAQ - http://jibbering.com/faq & newsgroup weekly
Javascript Best Practices - http://www.JavascriptToolbox.com/bestpractices/


VK写道:

< snip>
VK wrote:
<snip>
声明:
....如果所请求的时间框架符合甚至数量的刻度,则脚本更接近实时流程。如果请求的时间范围不适合偶数量的滴答,那么使用最接近的偶数蜱数量。 ...
Statement:
... . If the requested time frame fits into an even
amount of ticks then the script goes closer to the
real time flow. If the requested time frame doesn''t
fit into an even amount of ticks then the closest even
amoount of ticks is used instead. ...




那么关于偶数蜱的特别之处是什么?断言奇怪的

刻度被忽略似乎缺乏证据或理由。非常像你的陈述中的大部分




< snip - 与浏览器脚本无关的更不连贯的内容或

javascript>


Richard。



So what is so special about even numbers of ticks? Asserting that odd
ticks are skipped seems to lack evidence or reason. So much like most of
your statements.

<snip - more incoherent drivel unrelated to browser scripting or
javascript>

Richard.


这篇关于圣诞老人时间:是:浏览器的时间准确性的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆