itemrenderer

Flex: How to Reference What's Been Clicked When Using an ItemRenderer?

Hi, I've got a Tilelist and I'm using an ItemRenderer, which is a Button. I don't understand how to reference what was clicked. So, if the first tile (which is the first Obect) is clicked, how do I know that that particular one was clicked. <mx:ArrayCollection id="myAC"> <mx:Array> <mx:Object id="first" label="1" /> <mx:...

Datagrid with custom HeaderRenderer in Flex 4

Hi, I have a datagrid in my Flex App, and I;m uisng a custom HeaderRender. This HeaderRender has a checkbox. How can I control the checkbox from outside the HeaderRender? thanks! ...

How to implement an Object Pool for Flex Data/Item Renderers

You can hook into the creation of Flex 4 item renderers easily enough (through itemRenderer, or itemRendererFunction) allowing you to pull renderers from a custom object pool, but how would you put those renderers back into the pool? I understand that layout virtualization does a form of object pooling, but I'd like a way to hook in to ...

How to increase the buffer in Virtualized Flex 4 Layouts

Virtualized Layouts are nice, but I find that they often feel a bit "chunky" due to the "tightness" of the virtual range. This could be improved by increasing the range - one or two steps ahead (and behind) would often be enough to improve the "responsiveness" of the list, especially when external resources (like images) need to be loade...

flex tree custom item renderer children creation

Hi, I have created a custom item renderer for the tree, i have added some children in create children function, my problem is that sometimes i need to show these children and sometimes i don't, depending on clicking on a button which also i have added at create children, the problem is that i had to create the item even if i don't want ...

How do you make a TileList's itemrenderer size itself to the content of its data?

(Flex 3) I have a horizontally oriented TileList that is using an ArrayCollection as its data provider, and an ItemRenderer based on a simple mx:Text component. How can I force newly added tiles to size themselves (specifically width) dynamically, according to the width of the element being added? I've tried some invalidateDisplayLis...

Flex 4 Drag-n-Drop with custom DragProxy

Hi, I'm doing the drag an drop of an ItemRenderer manually (DataGrid) and want to know how to generate a custom DragProxy of a component that hasn't been added to the display list. I tried something like this but didn't work: private function doDrag(event:MouseEvent):void { var dragSource:DragSource = new DragSource(); d...

Referencing and setting a single item renderer instance in a Flex Tree at runtime.

Hi, Anyone know how to change a single instance of an item renderer for a Flex tree item at runtime? To reiterate, I'm not trying to change the entire tree's item renderer like this: tree.itemRenderer = new ClassFactory(ItemRenderer2); I'm trying to change the item renderer of a single tree item like this (the following code doe...

Flex 4: Item renderer and setting values for named objects (Odd Bug)

Hi, I have a custom component as an item renderer. In this renderer there is an item called dlFirstChoice. Now when I add more items to this list and force the list to rebuild itself something odd happens. Part of the creation of the renderer I set a default selection for the DropDownlist as follows: dlFirstChoice.selectedIndex=0 Th...

How to set item renderer for ListView in ext-gwt?

I have a ListView in ext-gwt and I'm adding some custom data to it. How can I set an item renderer on the ListView? As of right now, whenever an item is added, there's just a small line representing each entry in the view. Here's my basic code: import com.extjs.gxt.ui.client.store.ListStore; import com.extjs.gxt.ui.client.widget.Lis...

Flex 3: TextInput as ItemRenderer for CheckBox in ComboBox?

I need to create a Flex component similar to ComboCheck (by Arcadio Carballares). What I need is a ComboBox with CheckBox and TextInput instead of Checkbox's label. If CheckBox is selected the TextInput is enabled and editable, other way it's disabled. Do you have an idea of the easiest way to achieve it? ...

Custom Combo box itemrenderer in Flex Datagrid.

Hey, A combo box as an item renderer for a data cell in a Flex Datagrid has been demostrated at various blogs. What if that combo box has to have an external dataprovider that has to be set at the time of converting the renderer class to a ClassFactory. Can this be done? Or is there a workaround? Thanks in advance. ...

How can I get the Item Renderer that is at the top of the viewport in a Flex Spark List?

I have a Flex Spark List (well it's a Tree to be precise but it renders as a list) and as I'm scrolling through it I want to provide information about the item that is currently at the top of the list in context to the viewport. So this could be the 100th item in the list depending on how far you've scrolled down. ...

How can I get the ItemRenderer of a Flex Spark List from its DataProvider Object?

In Flex I can create an ItemRenderer to represent each item in the Lists DataProvider but how do I access the instance of the ItemRenderer via the DataProviders Object? Something like myList.getItemRenderer(dp.getItemAt(10)); ...

Dynamic Spark DropDownList ItemRenderer within Flex Datagrid

I have a datagrid which contains a Spark dropdownlist that needs to obtain dynamic data. The datagrid uses a separate dataProvider. When I use a static ArrayCollection within my ItemRenderer, it works (please see listing 1). However, when I use Swiz to mediate a 'list complete' event to load the ArrayCollection, the dropdownlist does n...

Flex Itemrenderer issue with DropDown Control

I want to show rich text in dropdown control, for which I am using the following renderer. <?xml version="1.0" encoding="utf-8"?> <mx:HBox xmlns:fx="http://ns.adobe.com/mxml/2009" xmlns:s="library://ns.adobe.com/flex/spark" xmlns:mx="library://ns.adobe.com/flex/mx"> <fx:Script> <![CDATA[ import spark.utils.TextFlo...

Setting Focus on a List ItemRenderer with TextArea inside?

I've wrote a custom itemrenderer for a List component (Flex 3.5) which is a VBox with a Label and a TextArea wrapped inside. All works fine so far but I want the TextArea in the first itemrenderer to receive focus so that it instantly becomes editable when tabbing onto the List. Is that possible and if how would I achieve this? I've alr...