PDA

View Full Version : Shifting background colors. How to do it?



hugh71158
September 7th, 2008, 01:47 AM
Hi all,

I was looking at a site - http://www.salleephotography.com - and I was wondering how the background colors can be made to change in this way?

I have a component that I want to drop on the stage, but have the background color change as each image loads.

Can anyone tell me how to achieve this before I have no more hair left? :puzzle:

Thanks a lot!

Hugh

Krilnon
September 7th, 2008, 02:06 AM
actionscript color tween

hugh71158
September 9th, 2008, 11:56 PM
actionscript color tween

Hi,

thanks for the reply.

I am almost there I think - the code below gives me a red background, but I am completely stumped as to what to script to make the slideshow cycle through different colored backgrounds.

Can you help?

Thanks.

Krilnon
September 9th, 2008, 11:57 PM
Where is the code that you are referring to?

hugh71158
September 10th, 2008, 12:06 AM
Where is the code that you are referring to?

Ah,

I just realized I had not pasted it in when your message came through. It is:

stop();

listenerObject = new Object();
listenerObject.transition = function( eventObject )

{
var _color = new Color(myThumbImager2.bg);
_color.setRGB(0xFF0000); //red
}
myThumbImager2.addEventListener("transition", listenerObject )