February 18th, 2008 by Kyle
Tags: datagrid, Flex, idropinlistitemrenderer, ifocusmanagercomponent, itemeditor, itemrenderer
Posted in: Flex
Here is a sample that came about as usual, from working on an issue with a customer. I found I didn’t have a good example of a combobox itemEditor. This sample came about when moving from using a combobox as an inline editor to moving to a combobox within a custom component as an editor. Wrapping the combobox in a VBox within the custom component caused some errors and undesirable behavior. In order to wire up data and tabbing/focus behavior you have to remember you component should implement IDropInListItemRenderer and IFocusManagerComponent. See the following sample code and running sample:
App:
<mx :Application xmlns:mx="http://www.adobe.com/2006/mxml">
<mx :XML id="xml" source="weather.xml"/>
</mx><mx
variableRowHeight="true" editable="true" rowHeight="50"
width="300" height="300">
</mx><mx :columns>
<mx
</mx><mx
</mx><mx :itemEditor>
</mx><mx :Component>
</mx><mx :ComboBox editable="true">
</mx><mx :dataProvider>
</mx><mx :String>Mild</mx>
<mx :String>Hot</mx>
<mx :String>Foggy</mx>
<mx :String>Rainy</mx>
<mx :String>Snow</mx>
<mx
itemEditor="CloudCover"/>
24 Comments »

Recent Comments