ecms_fullscreen.js
1.69 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
var lstart=0
var loop=true
var speed=85
var pr_step=3
var newspeed=800
var newspeed2=0
function makeObj(obj,nest){
nest=(!nest) ? '':'document.'+nest+'.'
this.css=(document.layers) ? eval(nest+'document.'+obj):eval(obj+'.style')
this.scrollHeight=(document.layers) ?
this.css.document.height:eval(obj+'.offsetHeight')
this.scrollWidth=(document.layers) ?
this.css.document.width:eval(obj+'.offsetWidth')
this.up=goUp
this.obj = obj + "Object"
eval(this.obj + "=this")
return this
}
function goUp(speed){
if(parseInt(this.css.top)>-(this.scrollHeight-0)){
this.css.top=parseInt(this.css.top)-pr_step-1
setTimeout(this.obj+".up("+speed+")",35)
}else {
if(navigator.appName == "Netscape")
{
tome=setInterval(this.obj+".setClipne()",50)}
else{
tome=setInterval('setClipie()',50)
tmp=DGbanner4Cont.style.clip;
}
}
}
function setClipne(){
//this.css.clip.right=this.css.clip.right-pr_step;
//this.css.clip.left=this.css.clip.left+pr_step;
//temp=parseInt(this.css.clip.right)-parseInt(this.css.clip.left);
if(temp==0)
{clearInterval(tome);
document.DGbanner4Cont.document.DGbanner4News.visibility="hide";
document.DGbanner4Cont.visibility="hide";
}
}
function setClipie()
{
newspeed=newspeed-pr_step;
newspeed2=newspeed2+pr_step;
temp="rect(0px "+newspeed+"px 600px "+newspeed2+"px)";
this.css.clip=temp;
if(newspeed<newspeed2)
{
clearInterval(tome);
DGbanner4News.style.display="none"
DGbanner4Cont.style.display="none"
}
}
function slideInit(){
oSlide=makeObj('DGbanner4News','DGbanner4Cont')
oSlide.css.top=lstart
oSlide.up(speed)
}
function myload(){
setTimeout("slideInit()",4000);
}
myload()