Have you tried setting the icon property on the child containers? This
worked for me. If you need it to be dynamic, then you could do that
same setStyle call you are doing below, just on the children of the
Accordion, not the headers. Hope this helps!
[Bindable]
[Embed(source="images/Company-Icon.png")]
public var companyIcon:Class;
[Bindable]
[Embed(source="images/Market-Icon.png")]
public var marketIcon:Class;
<mx:Accordion>
<mx:VBox icon="{ companyIcon }" />
<mx:VBox icon="{ marketIcon }" />
</mx:Accordion>
Dustin Mercer
________________________________
From: [email protected] [mailto:[EMAIL PROTECTED] On
Behalf Of dorkie dork from dorktown
Sent: Wednesday, December 13, 2006 12:42 PM
To: [email protected]
Subject: [flexcoders]Does the Accordion have an Icon Function?
Does the Accordion have an iconFunction? Similar to the iconFunction
used in the Tree and List controls.
For example, this code is supposed to set the icon for headers 0 and 1
but each statement sets the icon across all headers.
[Bindable]
[Embed(source="images/Company-Icon.png")]
public var companyIcon:Class;
[Bindable]
[Embed(source="images/Market-Icon.png")]
public var marketIcon:Class;
// in init
navigationMenu.getHeaderAt(0).setStyle('icon', companyIcon);
navigationMenu.getHeaderAt(1).setStyle('icon', marketIcon);