Has anyone gotten this working correctly? I'm trying to do the same
thing, and having some issues.

1st is the issue Simeon mentions below, any time you select an item,
the dropdown closes. I looked at the source for ComboBox.as, and it is
handling the "change" and "click" events on the list, and closing the
dropdown. I don't see how to overcome this without implementing a
custom list control that masks those events (and use the
dropdownFactory property)... Anyone else have any ideas on this?

2nd, there is an "itemRenderer" property on the ComboBox class in
Flex2 Release. I have set this to a checkbox, and it actually
renderers little mini combobox skins around the checkboxes! Try the
code below! Any ideas?

thanks in advance,
Thunder

<?xml version="1.0" encoding="utf-8"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml";
layout="vertical">
        <mx:ComboBox id="combo" dataProvider="{comboDP}">
                <mx:itemRenderer>
                        <mx:Component>
                                <mx:CheckBox />
                        </mx:Component>
                </mx:itemRenderer>
        </mx:ComboBox>
        <mx:XMLListCollection id="comboDP">
                <mx:source>
                        <mx:XMLList xmlns="">
                                <row><label>North America</label><data>North 
America</data></row>
                                <row><label>South America</label><data>South 
America</data></row>
                                
<row><label>Europe</label><data>Europe</data></row>
                                <row><label>Asia</label><data>Asia</data></row>
                                
<row><label>Africa</label><data>Africa</data></row>
                        </mx:XMLList>
                </mx:source>
        </mx:XMLListCollection>
</mx:Application>



--- In [email protected], "Simeon Bateman" <[EMAIL PROTECTED]>
wrote:
>
> Thanks man,
> 
> That was exactly what I needed.  However I think I underestimated just
> how close that would get me to my goal.
> 
> I need it to stay open when I select a checkbox.  Any guesses at what
> method I need to extend to make be able to intercede the closing of
> the box?
> 
> Thanks for the help.
> 
> simeon
> 
> 
> --- In [email protected], "JesterXL" <[EMAIL PROTECTED]> wrote:
> >
> > Welcome to the pain... shot of morphine?
> > 
> > Matt had an old email that did it like this:
> > <mx:ComboBox dataProvider="{sizes.size}" 
> > creationComplete="event.target.getDropdown().cellRenderer =
> sizeRenderer; 
> > event.target.getDropdown().variableRowHeight=true" />
> > 
> > I did the same thing, only used the open event since then you're
> ensured the 
> > list is actually created, and you only set it once.
> >
>






--
Flexcoders Mailing List
FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt
Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com 
Yahoo! Groups Links

<*> To visit your group on the web, go to:
    http://groups.yahoo.com/group/flexcoders/

<*> To unsubscribe from this group, send an email to:
    [EMAIL PROTECTED]

<*> Your use of Yahoo! Groups is subject to:
    http://docs.yahoo.com/info/terms/
 


Reply via email to