Flex 4 breakpoints are never reached when using inline item renderers

I am having problems debugging my Flex 4 application.
I have a file with both mxml inline item renderers and AS3 code.
When I now put a breakpoint inside that file and start my application it is immediately marked with an x and never reached when I run the code.
When I instead for example use a List with a skin that includes the item renderer everything works perfectly and the breakpoints are reached.
Anyone experiencing the same behavior or any suggestions?

4 comments
Comment actions Permalink

What is exact Flex SDK version?
(x) breakpoint means that debugger said 'No executable code at this line'. Is it possible to create some small sample to reproduce the problem? We'll see if it can be workarounded.

0
Comment actions Permalink

Hi,
my Flex SDK version is 4.0.0 build 14159.
I didn't have time to switch to the new 4.1 version yet.
A sample application that reproduces the problem for me is this:

<?xml version="1.0"?>
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
               xmlns:s="library://ns.adobe.com/flex/spark"
               creationComplete="init()">

    <fx:Script>
        <![CDATA[
        import mx.collections.ArrayCollection;

        private function init():void
            {
                var tmpCollection:ArrayCollection = new ArrayCollection();
                var tmpObj:Object;
                for (var i:int = 0; i < 10; i++){
                    tmpObj = new Object();
                    tmpObj.text = i.toString();
                    tmpCollection.addItem(tmpObj);
                }
                dataGroup.dataProvider = tmpCollection;
            }
        ]]>
    </fx:Script>

    <s:DataGroup id="dataGroup" width="100%">
        <s:layout>
            <s:VerticalLayout/>
        </s:layout>
        <s:itemRenderer>
            <fx:Component>
                <s:ItemRenderer autoDrawBackground="false" width="100%">
                    <s:Label text="{data.text}" />
                </s:ItemRenderer>
            </fx:Component>
        </s:itemRenderer>
    </s:DataGroup>

</s:Application>

I can't step into the init() function when debugging although the code is clearly executed.

0
Comment actions Permalink

Thank you, reproduced.
Looks like a bug of fdb tool. Does this work in any other Flex IDE?
You may open an issue and we'll try to workaround it http://youtrack.jetbrains.net/

0

Please sign in to leave a comment.