Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

Professional Opinions
Ask a Question
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE

troubleshooting Question

A button & image inside a tileList

Avatar of activeRoy
activeRoy asked on
Adobe FlashApache Flex
2 Comments1 Solution665 ViewsLast Modified:
                    <mx:TileList width="100%" height="100%" id="product_tile" itemRenderer="CustomItemRenderer" 
private function tileList_itemClick(evt:ListEvent):void { 
                img = new Image(); 
                // img.width = 300; 
                // img.height = 300; 
                img.maintainAspectRatio = true; 
                img.addEventListener(Event.COMPLETE, image_complete); 
                img.addEventListener(ResizeEvent.RESIZE, image_resize); 
                img.addEventListener(MouseEvent.MOUSE_OUT, image_click); 
				img.addEventListener(MouseEvent.MOUSE_DOWN, image_start_drag);
				img.addEventListener(MouseEvent.MOUSE_UP, image_stop_drag);				
                img.source = "http://localhost/funktion/templates/index/productimg/big/" + noS(evt.itemRenderer.data.spic);
                img.setStyle("addedEffect", image_addedEffect); 
                img.setStyle("removedEffect", image_removedEffect); 
                if (evt.itemRenderer.data.spic != "no_photo80x80.gif") {
				PopUpManager.addPopUp(img, this, true); 
<?xml version="1.0" encoding="utf-8"?> 
<!-- http://blog.flexexamples.com/2008/03/08/creating-a-simple-image-gallery-with-the-flex-tilelist-control/ --> 
<mx:VBox xmlns:mx="http://www.adobe.com/2006/mxml" 
        verticalAlign="middle" width="150" height="180">  

	<mx:Image source="http://localhost/funktion/templates/index/productimg/{data.spic}" />
    <mx:TextArea text="{data.name}" styleName="myFontStyle" wordWrap="true" editable="false" /> 
	<mx:Button label="details"  />


The problem is, the tilelist itemClick will cover the button onclick or the image click function. that means,
i only want to click the image to enlarge the image, and click the button show alert box. But now, i click the button (actually clicking the tile item), will also enlarge the image and show the alert box....
Avatar of mbiqbal
mbiqbalFlag of Pakistan image

Our community of experts have been thoroughly vetted for their expertise and industry experience.

This problem has been solved!
Unlock 1 Answer and 2 Comments.
See Answers