i'm facing with this problem: I've a module containing something like this:
<s开发者_运维知识库:TextInput id="query"
width="100%"
minHeight="50"
change="doQuery"/>
<s:List id = "items"
width="100%"
height="100%"
minHeight="200"
maxHeight="200"
itemRenderer = "renderer.myCustomRenderer"
dataProvider = "{itemList}"/>
my custom item renderer need to know what I'm writing into 'query' TextInput. Is there a way to pass query.text string to my renderer? Thanks a lot
You need to assign itemRenderer property at runtime when query TextInput changes :
var myRenderer:myCustomRenderer = new ClassFactory(myCustomRenderer);
sparkRenderer.properties = { query: query.text };
items.itemRenderer = sparkRenderer
精彩评论