How do I restyle an Adobe Flex Accordion to include a button in each canvas header?

Posted by Shawn Simon on Stack Overflow See other posts from Stack Overflow or by Shawn Simon
Published on 2008-08-14T20:25:07Z Indexed on 2010/04/10 8:03 UTC
Read the original article Hit count: 278

Filed under:
|

Here is the sample code for my accordion:

<mx:Accordion x="15" y="15" width="230" height="599" styleName="myAccordion">
	<mx:Canvas id="pnlSpotlight" label="SPOTLIGHT" height="100%" width="100%" horizontalScrollPolicy="off">
		<mx:VBox width="100%" height="80%" paddingTop="2" paddingBottom="1"  verticalGap="1">
			<mx:Repeater id="rptrSpotlight" dataProvider="{aSpotlight}">			
				<sm:SmallCourseListItem 
					viewClick="PlayFile(event.currentTarget.getRepeaterItem().fileID);"
					Description="{rptrSpotlight.currentItem.fileDescription}"
					FileID = "{rptrSpotlight.currentItem.fileID}"	
					detailsClick="{detailsView.SetFile(event.currentTarget.getRepeaterItem().fileID,this)}"	
					Title="{rptrSpotlight.currentItem.fileTitle}"
					FileIcon="{iconLibrary.getIcon(rptrSpotlight.currentItem.fileExtension)}" />
			</mx:Repeater>
		</mx:VBox>
	</mx:Canvas>
</mx:Accordion>

I would like to include a button in each header like so:

wishful" onclick="alert('xss')

Thanks in advance...

© Stack Overflow or respective owner

Related posts about flex

Related posts about actionscript-3