Hi David,

For the dimming you could set the alpha of each image to .5 to dim them and change it to 1 as part of doZoom, even perhaps come up with a fade component? (Maybe one exists I haven't played with transitions yet)

The image component has a click event so you just need to write a method to call when the image is clicked
<mx:Image id="img1"
source="@Embed(source='galleries/Vacation1.jpg')"
scaleX=".8" scaleY=".8"
alpha=".5"
rollOver="doZoom(event)"
rollOut="doZoom(event)"
click="myGotoURLMethod(event)"/>

I'm messing with TileList at the moment and I'm wondering if Tile might be an easier move having seen your email.

Thanks - hope I've helped you too,

Phil

envidobi wrote:

Hi all,
I"m trying get a tile list of 5 static images that will be listed in a
tile list. Upon mouse over, a zoom effect will be given, and upon
mouse out the zoom effect will be given again. I would also like, but
haven't figure it out, to be able to click the image and go to a URL.
My dillema is that when i run this code below, i get funky response to
the zoom. Sometimes the zoom stays enlarged if i pan in between the
images. They seem to go out to the right, and i'd like them to come
straight out. Also, is there a way i can make them dim when they're
not being moused over?
Thanks for any help at all! :)
CODE:
<?xml version="1.0" encoding="utf-8"?>
<!-- Simple example to demonstrate the Zoom effect. -->
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml"
backgroundColor="#000000" horizontalAlign="center" verticalAlign="middle"
paddingTop="5" paddingLeft="10" paddingRight="10" paddingBottom="5">

<mx:Script>
<![CDATA[
import flash.events.MouseEvent;

public function doZoom(event:MouseEvent):void {
if (zoomAll.isPlaying) {
zoomAll.reverse();
}
else {
// If this is a ROLL_OUT event, play the effect
backwards.
// If this is a ROLL_OVER event, play the effect
forwards.
zoomAll.play([event.target], event.type ==
MouseEvent.ROLL_OUT ? true : false);
}
}
]]>
</mx:Script>

<mx:Zoom id="zoomAll" captureRollEvents="true" zoomWidthTo="1"
zoomHeightTo="1" zoomWidthFrom=".8" zoomHeightFrom=".8" />
<mx:Tile width="100%" verticalGap="25">

<mx:Image id="img1"
source="@Embed(source='galleries/Vacation1.jpg')"
scaleX=".8" scaleY=".8"
rollOver="doZoom(event)"
rollOut="doZoom(event)"/>

<mx:Image id="img2"
source="@Embed(source='galleries/Vacation1.jpg')"
scaleX=".8" scaleY=".8"
rollOver="doZoom(event)"
rollOut="doZoom(event)"/>

<mx:Image id="img3"
source="@Embed(source='galleries/Vacation1.jpg')"
scaleX=".8" scaleY=".8"
rollOver="doZoom(event)"
rollOut="doZoom(event)"/>

<mx:Image id="img4"
source="@Embed(source='galleries/Vacation1.jpg')"
scaleX=".8" scaleY=".8"
rollOver="doZoom(event)"
rollOut="doZoom(event)"/>

<mx:Image id="img5"
source="@Embed(source='galleries/Vacation1.jpg')"
scaleX=".8" scaleY=".8"
rollOver="doZoom(event)"
rollOut="doZoom(event)"/>
</mx:Tile>

</mx:Application>

Thanks again,
David


-- 
______________________________________________________________ 
Phil Marston 
Technology Enhanced Learning
Centre for Learning & Teaching 
University of Aberdeen
Aberdeen
AB24 3QY

Email: [EMAIL PROTECTED]
Tel: +44(0)1224 273329
Mob: +44(0)7798 723660 
Web: http://www.abdn.ac.uk/clt/
______________________________________________________________

The University of Aberdeen Open Day 29th August 2006
Booking is essential
www.abdn.ac.uk/openday
email [EMAIL PROTECTED]
or call 0800 027 1495
__._,_.___

--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com





SPONSORED LINKS
Software development tool Software development Software development services
Home design software Software development company


YAHOO! GROUPS LINKS




__,_._,___

Reply via email to