开发者

How Can I Add a Progress Bar to an Image in a Custom Component?

I'd like to add a progress bar to my image. The problem is that the image is in a custom component. In the Application, I make server call to get the pathway to the photo. I set photo1 in the Application. Please find below the custom component:

<mx:Metadata>
    [Event("change", type="mx.events.Event")]
</mx:Metadata>

<mx:Script>
    <![CDATA[
        [Bindable]
        public var photo1:String; 
    ]]>
</mx:Script>

<mx:Accordion id="accordion"
    resizeToContent="true"
    width="100%" 
    buttonMode="true" >


                 <mx:VBox label="Image" 
         width="100%"
         height="319">

                     <mx:Image id="neighborhoodPic1" source="{photo1}"/>   
             </mx:VBox> 

    </mx:Accordion>


    <mx:ControlBar styleName="white" height="40">
    <mx:Button id="flipButton1" x="53" y="65" label="Flip Me" 
        click="dispatchEvent( new Event( Event.CHANGE ) );" />
    </开发者_开发百科mx:ControlBar>

How can I add a progress bar to neighborhoodPic1? Is it possible to add a progress bar to a custom component?

Thank you!

-Laxmidi


Yes, this should be close...

<mx:ProgressBar source="neighborhoodPic1" mode="polled" />
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜