Take a look at DynImage. This will probaly be what you need. Also, setBgImage in IE
is a pain because it causes the image to reload when ever you move/size the layer
again.
--
// Robert Rainwater
--
DynAPI Homepage: http://dynapi.sourceforge.net/
DynAPI Snapshots: http://dynapi.sourceforge.net/snapshot/
On Tuesday, February 27, 2001 1:43:55 PM Terry Valladon wrote:
> Hello, I was working with some layers and images last night and came to the
> discovery that setHTML is very slow compared to setBgImage, and I was
> wondering, if in light of this, anyone know a method faster then setBgImage
> of assigning an image to a layer. At this point setBgImage seems my best bet
> but I will be dealing with a 9x9x4 grid of layers (324 layers), so anything
> faster would be great.
>
> Also I have the following code:
> }
> DynAPI.onLoad = function() {
> myListener = new EventListener(DynAPI.document)
> myListener.onkeyup=function(e) {
> onKeyPress()
> }
> DynAPI.document.addEventListener(myListener)
> }
> function onKeyPress () {
> var keycode;
> if (window.event) keycode = window.event.keyCode;
> else if (e) keycode = e.which;
> else return true;
> if (keycode == 38){myLayerPlayer.moveTo(myLayerPlayer.x, myLayerPlayer.y -
> 32)}
> if (keycode == 40){myLayerPlayer.moveTo(myLayerPlayer.x, myLayerPlayer.y +
> 32)}
> if (keycode == 39){myLayerPlayer.moveTo(myLayerPlayer.x + 32,
> myLayerPlayer.y)}
> if (keycode == 37){myLayerPlayer.moveTo(myLayerPlayer.x - 32,
> myLayerPlayer.y)}
> return true
> }
>
> and this works great unless the person clicks on a layer or image on the
> page, when this happens it no longer captures key events. I was hoping
> someone could slap me around a bit and show me what it is that I am doing
> wrong...
>
> Thank you for your time,
> Terry
>
>
> ***********************************************************************
> This email and any files transmitted with it are confidential and
> intended solely for the use of the individual or entity to whom
> they are addressed. This footnote also confirms that this email
> message has been swept for the presence of computer viruses.
> ***********************************************************************
_______________________________________________
Dynapi-Help mailing list
[EMAIL PROTECTED]
http://lists.sourceforge.net/lists/listinfo/dynapi-help