鼠标转动时钟.doc_第1页
鼠标转动时钟.doc_第2页
鼠标转动时钟.doc_第3页
鼠标转动时钟.doc_第4页
鼠标转动时钟.doc_第5页
已阅读5页,还剩23页未读 继续免费阅读

下载本文档

版权说明:本文档由用户提供并上传,收益归属内容提供方,若内容存在侵权,请进行举报或认领

文档简介

!- BegindCol=99CC00;fCol=FF9900;sCol=3366FF;mCol=3366FF;hCol=3366FF;ClockHeight=40;ClockWidth=40;ClockFromMouseY=0;ClockFromMouseX=100;d=new Array(SUNDAY,MONDAY,TUESDAY,WEDNESDAY,THURSDAY,FRIDAY,SATURDAY);m=new Array(JANUARY,FEBRUARY,MARCH,APRIL,MAY,JUNE,JULY,AUGUST,SEPTEMBER,OCTOBER,NOVEMBER,DECEMBER);date=new Date();day=date.getDate();year=date.getYear();if (year 2000) year=year+1900;TodaysDate= +ddate.getDay()+ +day+ +mdate.getMonth()+ +year;D=TodaysDate.split();H=.;H=H.split();M=.;M=M.split();S=.;S=S.split();Face=1 2 3 4 5 6 7 8 9 10 11 12;font=Arial;size=1;speed=0.6;ns=(document.layers);ie=(document.all);Face=Face.split( );n=Face.length;a=size*10;ymouse=0;xmouse=0;scrll=0;props=;props2=;Split=360/n;Dsplit=360/D.length;HandHeight=ClockHeight/4.5HandWidth=ClockWidth/4.5HandY=-7;HandX=-2.5;scrll=0;step=0.06;currStep=0;y=new Array();x=new Array();Y=new Array();X=new Array();for (i=0; i n; i+)yi=0;xi=0;Yi=0;Xi=0Dy=new Array();Dx=new Array();DY=new Array();DX=new Array();for (i=0; i D.length; i+)Dyi=0;Dxi=0;DYi=0;DXi=0if (ns)for (i=0; i D.length; i+)document.write(+props2+Di+);for (i=0; i n; i+)document.write(+props+Facei+);for (i=0; i S.length; i+)document.write(+Si+);for (i=0; i M.length; i+)document.write(+Mi+);for (i=0; i H.length; i+)document.write(+Hi+);if (ie)document.write();for (i=0; i D.length; i+)document.write(+props2+Di+);document.write();document.write();for (i=0; i n; i+)document.write(+props+Facei+);document.write();document.write();for (i=0; i H.length; i+)document.write(+Hi+);document.write();document.write();for (i=0; i M.length; i+)document.write(+Mi+);document.write()document.write();for (i=0; i S.length; i+)document.write(+Si+);document.write()(ns)?window.captureEvents(Event.MOUSEMOVE):0;function Mouse(evnt)ymouse = (ns)?evnt.pageY+ClockFromMouseY-(window.pageYOffset):event.y+ClockFromMouseY;xmouse = (ns)?evnt.pageX+ClockFromMouseX:event.x+ClockFromMouseX;(ns)?window.onMouseMove=Mouse:document.onmousemove=Mouse;function ClockAndAssign()time = new Date ();secs = time.getSeconds();sec = -1.57 + Math.PI * secs/30;mins = time.getMinutes();min = -1.57 + Math.PI * mins/30;hr = time.getHours();hrs = -1.575 + Math.PI * hr/6+Math.PI*parseInt(time.getMinutes()/360;if (ie)Od.style.top=window.document.body.scrollTop;Of.style.top=window.document.body.scrollTop;Oh.style.top=window.document.body.scrollTop;Om.style.top=window.document.body.scrollTop;Os.style.top=window.document.body.scrollTop;for (i=0; i n; i+)var F=(ns)?document.layersnsFace+i:ieFacei.style;F.top=yi + ClockHeight*Math.sin(-1.0471 + i*Split*Math.PI/180)+scrll;F.left=xi + ClockWidth*Math.cos(-1.0471 + i*Split*Math.PI/180);for (i=0; i H.length; i+)var HL=(ns)?document.layersnsHours+i:ieHoursi.style;HL.top=yi+HandY+(i*HandHeight)*Math.sin(hrs)+scrll;HL.left=xi+HandX+(i*HandWidth)*Math.cos(hrs);for (i=0; i M.length; i+)var ML=(ns)?document.layersnsMinutes+i:ieMinutesi.style;ML.top=yi+HandY+(i*HandHeight)*Math.sin(min)+scrll;ML.left=xi+HandX+(i*HandWidth)*Math.cos(min);for (i=0; i S.length; i+)var SL=(ns)?document.layersnsSeconds+i:ieSecondsi.style;SL.top=yi+HandY+(i*HandHeight)*Math.sin(sec)+scrll;SL.left=xi+HandX+(i*HandWidth)*Math.cos(sec);for (i=0; i D.length; i+)var DL=(ns)?document.layersnsDate+i:ieDatei.style;DL.top=Dyi + ClockHeight*1.5*Math.sin(currStep+i*Dsplit*Math.PI/180)+scrll;DL.left=Dxi + ClockWidth*1.5*Math.cos(currStep+i*Dsplit*Math.PI/180);currStep-=step;function Delay()scrll=(ns)?window.pageYOffset:0;Dy0=Math.round(DY0+=(ymouse)-DY0)*speed);Dx0=Math.round(DX0+=(xmouse)-DX0)*speed);for (

温馨提示

  • 1. 本站所有资源如无特殊说明,都需要本地电脑安装OFFICE2007和PDF阅读器。图纸软件为CAD,CAXA,PROE,UG,SolidWorks等.压缩文件请下载最新的WinRAR软件解压。
  • 2. 本站的文档不包含任何第三方提供的附件图纸等,如果需要附件,请联系上传者。文件的所有权益归上传用户所有。
  • 3. 本站RAR压缩包中若带图纸,网页内容里面会有图纸预览,若没有图纸预览就没有图纸。
  • 4. 未经权益所有人同意不得将文件中的内容挪作商业或盈利用途。
  • 5. 人人文库网仅提供信息存储空间,仅对用户上传内容的表现方式做保护处理,对用户上传分享的文档内容本身不做任何修改或编辑,并不能对任何下载内容负责。
  • 6. 下载文件中如有侵权或不适当内容,请与我们联系,我们立即纠正。
  • 7. 本站不保证下载资源的准确性、安全性和完整性, 同时也不承担用户因使用这些下载资源对自己和他人造成任何形式的伤害或损失。

最新文档

评论

0/150

提交评论