Can't get SlideTo to work for Mozilla 0.7 (inline layers). Also, I would
like to know what is the bare minimum that I need to use:
moveTo, slideTo, setVisible... using Inline layers....  That's all I
basically use.  I'm concerned about size of js code...  I don't
understand why I need the listeners to do slideTo.  I'm used to the old
dynapi from Dan Steinman and trying to covert to the new one.   I only
use inline layers.

Here is my code (based on example):

<html>
<head>
<title>DynAPI Examples - Slide Animation (Path Animation)</title>
<script language="Javascript" src="src/dynapi.js"></script>
<script language="Javascript">
DynAPI.setLibraryPath('src/lib/');
DynAPI.include('dynapi.api.*');
DynAPI.include('dynapi.ext.inline.js')
DynAPI.include('dynapi.util.thread.js');
DynAPI.include('dynapi.util.pathanim.js');
</script>
<script language="Javascript">

DynAPI.onLoad = function() {

 var myLayer = new Object();
 myLayer = this.document.all['layer1']
 myLayer.setBgColor('#c0c0c0')
 myLayer.setSize(200,200)
 myLayer.moveTo(100,100)
 myLayer.setVisible(true)

 var listener = new EventListener();
 listener.onpathstart = function(e) {
  status = "start";
 }
 listener.onpathrun = function(e) {
  var o = e.getSource();
  status = "play "+o.x+" "+o.y;
 }
 listener.onpathstop = function(e) {
  var o = e.getSource();
  status = "stop "+o.x+" "+o.y;;
 }
 myLayer.addEventListener(listener);
 myLayer.slideTo(300,300,2,2);
}

//-->
</script>
</head>

<body bgcolor="#ffffff">

<div id="layer1" style="position:absolute;visibility:hidden;">
This is layer1
</div>

</body>
</html>



_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-help

Reply via email to