Flex :: List Component That Acts As If Control Was Permanently Pressed

Jun 1, 2010

I have a list control and i want the user to be able to select many items at a time. Thus I want it to act that if the control key is pressed while he is clicking. Eg if he clicks on a selected row it should become unselected and if he clicks on a unselected row it should become selected.

View 1 Replies


Similar Posts:


ActionScript 3.0 :: Flash Control List Component - How To Unpopulate

Sep 24, 2010

I have a List (fl.controls.List) component... I can successfully populate this component with String data. The problem occurs when I try to unpopulate the list. The only function available is "removeAll()" I couldnt see a different function.

I am using it this way
Code:
function removeFromList(e:MouseEvent):void {
if(list.selectedItem) {
list.removeAll();
}
When I've been using list.removeSelected() I don't think there is a function as this?

View 3 Replies

Flex :: MX List ItemRollOver Event Equivalent On A Spark List Control?

May 26, 2011

Flex 3 List control had a itemRollOver event. Flex 4 List doesn't have it. Is there an equivalent or a workaround for this issue?

View 2 Replies

Flex :: Make A Custom Component Or Extend The List Component For A 2D Top Down View MAP ?

Nov 11, 2010

I'm building a top view 2D map, that it's objects are stored on the server.The kind of objects are 10 and might be a photo, label, button, lists, mix of them or labels with tooltips.The component must request the "areas" that are missing on screen.An area is 1000x1000 px and is cached in flex.To move in the map, will be like in google maps (drag-and-drop).I should be able to have another list and move objects from one to another using drag-an-drop on objects. Ex.: I grab an objects from a list and I move it on this map, I release the mouse button and the item is placed there.Now the problem is: I build a custom component for this trying to emulate the item renderer for performance and recyclage, implement drag-and-drop on objects and request the areas that are missing?

or

I extend the List component from spark and I add some features as multiple kind of itemrenderers and use recycle on them. Of course it must be able to request the missing areas on the screen and cache it's data.Maybe create a custom layout is needed too.What I need is something that must be really fluid, so the lighter this component is, the better.

UPDATE: *There will be not any object over another.

*I will not use hitTest on bitmaps because all bitmaps are wrapped in another component,as they,for now are itemrenderers.

Anyway I already begin to do this using a class that extends the SkinnableDataContainer and a custom layout. As the layout is not like a grid, is sparse, random items at diferent points(x, y).How to get the localX and localY, relative to item renderer and not to the Spark List, from a DragEvent in Flex 4?

View 1 Replies

List Component - Populate A List Box Component Located Within A Separate Mc In Swf With An Array?

Jun 29, 2009

how to populate a list box component located within a seperate mc in my swf with an array... the array comes from a response from a webservice call. I am not currently on the computer with my source code available so lets just use the following....

listdata[i] = the array i want to populate the list box with..... (listdata1, listdata2, listdata3, listdata4, etc. etc.)
movieclip1 = the MC within my fla containing the list box component
mylist = the actual list component

... just not all that familiar with the format of actionscript when working with objects... using CS3 and as2 btw,

View 3 Replies

Flex :: Scrolling Of List Control Is Misbehaving?

Dec 22, 2009

I am having this very weird behavior with a mx:List control not scrolling properly.Here is a snippet:

<mx:List itemRenderer="customerRender" x="19" y="257" height="68" width="290" id="orderStatusHistoryList" color="#CCCCCC" rowHeight="35" ></mx:List>

The custom render creates a vBox that is 35 pixels high with some labels in it.Now, my dataProvider, set in the script block,is returning 3 items for the list (say item1, item2 and item3). Because of the height of the list control, only 2 are shown initially.Now for the weird part, when I scroll down the list to see the next item it is all messed up.

Initial display:
Item 1
Item 2

Display after clicking the scroll down button:

Item 2 (expected)
Item 1 (What the ?, this should be item 3)

Display after click the scroll down button one more time:

Item 1 (all wrong)

Now, if I increase the height of the list control,so it has enough room to display all three items, it displays fine.Also,I put a trace statement is the item render and flex is rendering all three items with the correct data.

View 1 Replies

Flex :: Set Color Of A Particular Row In List Control For Mobile?

Jul 13, 2011

I have a list in flex mobile project which contains multiple rows. I want to set color of specific rows based on some logic.

View 1 Replies

Flex :: Navigate In Spark List Control?

Aug 22, 2011

I'm building a mobile app, using spark list control. When user tap on a list item, i want it to navigate to that correspondence page

<s:List id="list" width="100%" height="100%" labelField=" label">
<s:dataProvider>
<s:ArrayList>

[Code].....
 
how do i code it so that when user tap on item label="Page One" it will navigate to PageOneView.mxml and if it tap on "Page Two" it will go to PageTwoView.mxml and so on.

View 1 Replies

Flex :: Drag And Drop Between List Control And Chart?

Feb 18, 2010

I am trying to implement a drag and drop function between a list control and a columnchart in Flex3. List items should, when dragged and dropped on the chart, be displayed raphically in the columnchart.Alas, dropping the listitems on the chart does not seem to result in a proper graph.Here my code till so far with regard to the drop part:

private function doDragDrop(event:DragEvent):void{
var ds:DragSource = event.dragSource;
var dropTarget:ChartBase=ChartBase(event.currentTarget);

[code]....

View 1 Replies

Flex :: Add Separator Between Items In A Spark List Control?

May 21, 2010

I have a s:List where I've defined my own itemRenderer, and would like to insert a horizontal line separating items, similar to the way the mx:LinkBar works. I don't want to have a line at the top or bottom of the list, so I can't just include an upper or lower border in the itemRenderer. I was hoping the itemRenderer could be made aware of its index in the list, but I don't see how.

View 2 Replies

Flex :: How To Set Variable Size For List Control Item

Jun 17, 2010

The following code display a list of comments using List control. The item height set to a fixed value (150), so it seems working: if the content is too long, the scrollbar shows. However, what I really want is not to set the height but let it to change according to the content size. Is there any way to accomplish this?

<mx:List id="commentList" width="100%" dataProvider="{commentSet.commentArrayColl}" rowCount="{commentSet.commentArrayColl.length}" >
<mx:itemRenderer> <mx:Component>
<mx:VBox width="100%" height="150" >
<mx:Text text="{data.commentContent}" />
<mx:Text text="{data.username} ({data.modified})"/>
</mx:VBox> </mx:Component>
</mx:itemRenderer> </mx:List>

To be more clear, I don't want to set the itemRenderer's VBox height to "150" or any other fixed value - but it'll only show one line of the text if I don't do it. So I'm looking for a way out of this. (If the VBox is not inside the itemRenderer, it'll auto adjust height as Text field string length grows - that's what I want.)

View 2 Replies

Flex :: Set The Scroll Position For A Spark List Control?

Aug 9, 2010

How can I set the scroll position for a Spark List control?

View 1 Replies

Flex :: Put XML Query Inside A Drop Down List Control?

Feb 7, 2011

I have this project for school where i have to populate a drop down list control from an xml file.I mange to do that for a label/text input control, but i can't seem to do that on a drop down.I get this error any time i tell him to "additem" with an xml query (not getting it with simple text):"#1009 Cannot access a property or method of a null object reference"[code]...

View 1 Replies

Flex :: Validate A <mx:List Component>?

Dec 26, 2009

How can I validate if atleast one item has been selected from a list, such that the selectedIndices is set to NULL at the init() of application?

View 1 Replies

Flex :: <mx:List> Is Hidden By Other UI Component

Jul 18, 2010

In flex UI, my <mx:list> can not be shown completely because of other component shelterring (for example: the refresh button shelter part of it ). How can I make the <mx:list> in front of all other UI component.

This is my code:

<s:HGroup verticalAlign="middle">
<s:Label text="Choose Log File"/>
<mx:ComboBox id ="logFileChooseCombo" dataProvider="{fileNameList}" width="150" color="0x000000"

[Code]....

View 1 Replies

Flex :: Extend A List To Add An UI Component?

Mar 2, 2011

How can I extend a spark list to add a UI component on it?

View 1 Replies

Flex :: Add Swipe In List Component ?

Mar 14, 2012

I have a list component in my app which shows some tiles and one can navigate through them horizontally and i was wondering how can i add the swipe functionality in it to the left or to the right,is this supported by default when the app is on a touch device? the list is like:

<s:List id="list2" width="100%" height="100%" dataProvider="{ recordingsShown }"
preinitialize="list2_preinitializeHandler(event)"
selectedIndex="0" visible="false">[code]............

View 1 Replies

Flex :: 3 - Adobe 3 List Control Selection And Change Event

Nov 22, 2009

I created a list control at runtime as following:

[Code]....

//Where myDataArray is an ArrayCollection consisting of my Custom ValueObjects. When i execute the code it displays my list with custom item renderer, which is fine. But when bring my mouse over it, it doesn't give any colour highlight which means it is not selecting. Secondly, when i click on any of the list item, it doesn't dispatch any change event. I tried a lot but couldn't understand it.

View 1 Replies

Actionscript 3 :: Make An Item In A Flex List Control Not Selectable?

Jan 12, 2010

Is it possible to make an item in a List control not selectable? If so, how would this be accomplished?

I've tried one thing so far. What I did was use a custom item renderer that checks for a value in the data property upon a FlexEvent.DATA_CHANGE event. If that value is not set, I tried setting the item renderer's selectable property to false. This, unfortunately, does not seem to work.

View 4 Replies

Flex :: Auto-select The First Index In A Sparks List Control?

Apr 11, 2010

i have a spark List control. it has a dataProvider that shows reply from twitter search.i have created a function for change handler like this:

protected function list_changeHandler(event:IndexChangeEvent):void
{
ta.text = coverflow.selectedItem.title;
}

so, whenever i select each of the items in the List i will see the message(ta.text)but now, instead of me manually clicking the first time, i want it to automatically click/select the first item and see the first message(ta.text)how do i do it?

View 4 Replies

Actionscript 3 :: Flex : Make A Generic List Control That Has X Buttons In It

Dec 3, 2010

I am trying to make a generic list control that has x buttons in it so that users can remove items from the list by clicking the x button. However, this list control needs to support item renderers while still standardizing the layout of items placed next to x buttons.

So I figure the best approach would be to extend the list control and use a renderer that draws the x button and combines that with what ever renderer the user supplies. Unfortunately I cannot figure out how to do that.

I tried overriding newInstance method from the IFactory interface and used that to create an HBox that contains my button and inserts the newInstance result from a user supplied renderer, however it wasn't complete. It displayed as I expected, but the mouse over effect only worked on the user supplied renderer portion and not the entire HBox that my custom renderer made.

View 3 Replies

Actionscript :: Target And Display An Object Of List Control In Flex

Oct 1, 2011

i have made a list control. i want to display the name of the objects in it in a text control box

the code i am using here is

public function add(event:MouseEvent):void
{
var str:String;
str = mylistcontrol.dataProvider.getItemAt(0).toString();

[Code]....

The problem with this code is i am using index value of 0. however i want to display the name of object on which i have clicked or which is highlighted.

View 1 Replies

Flex :: Accessing Children Of A List Component?

Apr 15, 2010

when I try to loop through the children of a List component that has buttons in it, I can't seem to access those children. I try

for(var btnNum:Number = 0; btnNum < myList.numChildren; btnNum++)
{

trace(myList.getChildAt(btnNum);[code]......

View 1 Replies

Flex :: Hide A List Component When It Contains No Items?

Apr 28, 2010

I have a List of items which is based on the contents of the "category" that a user selects

When the user changes selection, I change the dataProvider of the list be be the contents of the current category.

Sometimes the list contains items, sometimes it does not

Is there a way of hiding the list when it has no items?

I know that I could do this when setting the dataProvider, but it seems like there should be an event or something else that I could be using.

View 2 Replies

Flex :: Skinning Spark List Component?

Aug 2, 2010

How to skin spark List component so that every adjacent itemRenderer has different color (something like mx DataGrid)?

View 1 Replies

Flex :: Creating A Custom List Component

Jan 10, 2011

I'm trying to extend the mx:Box container so that two buttons sit on the outside of the container to cycle through it's contents (similar to a scrollbar).

I've made a custom component that looks basically
like "mx:HBox->mx:Button mx:Box mx:Button" where the buttons and box are children of the hbox.

How do I offer the user access to the box (say its dataProvider and itemRenderer) through my custom component?

So they just need to write 'local:MyCustomComponent dataProvider="rar" itemRenderer="rar"/>' and my box inside that component can use it?

View 1 Replies

Actionscript 3 :: Is There A Hierarchical List Component For Flex

Jun 9, 2011

I will implement this myself if I can't find it but after 30 minutes of searching on the web I'm a bit surprised this doesn't exist. Basically what I need is a hierarchical list component like the finder app on mac. I want the same functionality as a tree component but displayed as each level having it's own list resulting in multiple lists that depend on each other.

View 1 Replies

Actionscript 3 :: Flex: Can List Be Used To Display Control In Equally Sized Tiles

Sep 2, 2010

In one of the application I am working, List has been used. I am required to display items in the form of tiles. I do not want to change the component as of now. Is there any way to achieve this layout in list only.

View 3 Replies

Flex :: Creating A Dynamically Sized List Component

Aug 16, 2010

I need a List that resizes to exactly fit its content, unless that height exceeds its (dynamically sized) parent container. My requirements are as follows:

The component extends List, or at least acts similarly. variableRowHeight and wordWrap both equal to true. The height of the list cannot be less than minHeight (roughly 32px for scrollbar arrows). The height of the list cannot be greater than the height of the parent container .

Note that the parent container can be resized dynamically.

The height of the list should be updated as the size of both the contents and parent container changes.

Live updating would be preferable but not necessary.

There should be no scrollbars if the content height is less than the parent container height (sounds obvious, but I've had trouble with this too).

The trouble is that with variableRowHeight and wordWrap, it's very hard to know the size of the content at any given time. If the parent container's width is reduced, a line wrap may occur in the list which will change the height of the content. I know I can measure the height of the list content using measureHeightOfItems() + viewMetrics.top + viewMetrics.bottom, but when should I calculate that? What events should I listen for? And the thing I've had the most trouble with - when should I calculate it to set the size initially (i.e. just as the content has finished populating)?

View 1 Replies

Flex :: Populate The Tree Component With The Display List?

Sep 29, 2010

Is there a way display the display list in the Tree component. I could parse the display list into xml but then I would not be able to create a reference to the display object.

View 1 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved