Having problems with IntelliJ IDEA 9 sample Flex 4 generated application

I'm building an Flex 4 application using IntelliJ IDEA 9.0.2 generated sample Flex application. I replace the generated mxml with the following code from the book Hello Flex 4.
It simply crashes the browser when I run it. It says "Waiting for fpdownload.adobe.com..." and then crashes!
I tried it on both FF 3.5.9 and Chrome 4.

Any clues?

<?xml version="1.0" encoding="utf-8"?>
        width="100%" height="100%">
        public var _theory:String;
        public var _bread:Number = Number.NaN;
        <s:RadioButtonGroup id="moralityRBG"/>
        <s:RadioButtonGroup id="restaurantRBG"
                selectedValue="{_theory.length % 2 == 0 ? 'smoking' : 'non'}"/>        
    <s:Panel width="100%" height="100%" title="Simple Components!">
            <s:HorizontalLayout paddingLeft="5" paddingTop="5"/>
            <s:TextArea id="textArea" width="200" height="50" text="@{_theory}"/>
            <s:TextInput id="textInput" width="200" text="@{_theory}"/>
            <s:HSlider id="hSlider" minimum="0" maximum="11"
                       liveDragging="true" width="200" value="@{_bread}"/>
            <s:VSlider id="vSlider" minimum="0" maximum="11"
                       liveDragging="true" height="50" value="@{_bread}"/>
            <s:Button label="{_theory}" width="200" color="{alarmTB.selected ? 0xFF0000 : 0}"
                      click="_bread = Math.min(_theory.length, 11)"/>
            <s:CheckBox id="checkBox" selected="{_bread % 2 == 0}" label="even?"/>
            <s:RadioButton label="Good" value="good" group="{moralityRBG}"/>
            <s:RadioButton label="Evil" value="evil" group="{moralityRBG}"/>
            <s:RadioButton label="Beyond" value="beyond" group="{moralityRBG}"/>
            <s:RadioButton label="Smoking" value="smoking" group="{restaurantRBG}"/>
            <s:RadioButton label="Non-Smoking" value="non" group="{restaurantRBG}"/>
            <s:ToggleButton id="alarmTB" label="ALARM!"/>
            <s:NumericStepper id="numericStepper" value="@{_bread}"
                              minimum="0" maximum="11" stepSize="1"/>
            <s:Spinner id="spinner" value="@{_bread}"
                       minimum="0" maximum="11" stepSize="1"/>


1 comment
Comment actions Permalink

I got the clue. Its the two-way data bindings in action that used to work fine with Flex4-beta but break in Flex4-Final - according to the author Peter Armstrong :-)

Errata for the book is listed in this link


You may need to remove the @ sign from every control except TextArea and HSlider.



Please sign in to leave a comment.