home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Chip 2002 September (Special)
/
Chip-Special_2002-09_Digitalni-Video.bin
/
servis
/
wm9
/
mpsetupXP.exe
/
RCDATA
/
CABINET
/
wmploc.DLL
/
HTML
/
FLYOUT.HTC
< prev
next >
Wrap
Text File
|
2002-08-19
|
1KB
|
67 lines
<PUBLIC:COMPONENT lightWeight=true>
<PUBLIC:EVENT name="onflydone" ID=done />
<PUBLIC:PROPERTY NAME="speed" />
<PUBLIC:PROPERTY NAME="source" />
<PUBLIC:PROPERTY NAME="endPoint" />
<PUBLIC:METHOD NAME="flyout" />
<SCRIPT LANGUAGE="JScript">
var iEnd, iSpeed, iCount = 0;
function doflyout()
{
var iAdjust, ssty = source.style;
if (ssty.posLeft != iEnd)
{
if ((ssty.posLeft - iEnd) < iSpeed)
{
iAdjust = (ssty.posLeft - iEnd) / 4;
if (iAdjust < 4) iAdjust = ssty.posLeft - iEnd
}
else
iAdjust = iSpeed;
ssty.posLeft -= iAdjust;
window.setTimeout(doflyout, 1);
}
else
{
var e = createEventObject();
e.direction = 1;
e.page = source;
done.fire(e);
}
}
function flyaway()
{
var ssty = source.style;
if (ssty.posLeft < iEnd)
{
ssty.posLeft += iSpeed;
window.setTimeout(flyaway, 1);
}
else
{
var e = createEventObject();
e.direction = 0;
e.page = source;
done.fire(e);
}
}
function flyout(iDir)
{
iEnd = parseInt(endPoint);
iSpeed = parseInt(speed);
if (iDir == 1)
doflyout();
else
flyaway();
}
</SCRIPT>
</PUBLIC:COMPONENT>