Change it to <treeline:itemRenderer>.

Best Regards,
...aaron

On 11/17/07, quiet.mountain <[EMAIL PROTECTED]> wrote:
>
>   Hi all,
>
> This TileList was working fine:
>
> <mx:TileList id="allYarnsTL"
> dataProvider="{allYarnsAC}">
> <mx:itemRenderer>
> <mx:Component>
> <mx:Canvas>
> <mx:Image id="yarnImage"
> source="{data.image}"/>
> </mx:Canvas>
> </mx:Component>
> </mx:itemRenderer>
> </mx:TileList>
>
> I then needed to override some TileList behaviours. So I started to
> subclass TileList...
>
> package com.treelinerugs
> {
> import mx.controls.TileList;
>
> public class TestTileList extends TileList
> {
> public function TestTileList()
> {
> super();
> }
>
> }
> }
>
> and then created an instance as before...
>
> <treeline:TestTileList id="allYarnsTL"
> dataProvider="{allYarnsAC}">
> <mx:itemRenderer>
> <mx:Component>
> <mx:Canvas>
> <mx:Image id="yarnImage"
> source="{data.image}"/>
> </mx:Canvas>
> </mx:Component>
> </mx:itemRenderer>
> </treeline:TestTileList>
>
> But now I get a compile-time error "Could not resolve
> <mx:itemRenderer> to a component implementation."
>
> I can fix this by creating a separate component and creating the
> instance like this instead:
>
> <treeline:TestTileList id="allYarnsTL"
> dataProvider="{allYarnsAC}"
> itemRenderer="com.treelinerugs.TLItemRenderer">
>
> Why can't I define the itemRenderer in-line if I subclass TileList?
>
> Thanks, Rich
>
>  
>



-- 
Aaron Miller
Chief Technology Officer
Splash Labs, LLC.
[EMAIL PROTECTED]  |  206-328-5485
http://www.splashlabs.com

Reply via email to