Problem sorting list with virtual layout = false (and also with true)

Hi,
I've a problem sorting a list... or better... I've a problem showing the sorted list ;-)
I've a list of xml item. The list is shown with an item renderer.
my needs: a button to refresh data and a button to sort data.
useVirtualLayout = false
-> refresh works correctly, sort does not affect the view (even if the list is sorted correctly when printed with trace)
useVirtualLayout = true
-> sort works correctly, refresh reverse the list each time I press it (even if the list remain the same when printed with trace)
does any one have an idea?
thank you!!
MXML
<s:List dataProvider="{xmlListCollection}" width="100%" itemRenderer="myRenderer" minHeight="0" id="test" useVirtualLayout="false" >
<s:layout>
  <s:VerticalLayout clipAndEnableScrolling="true"/>
</s:layout>
</s:List>
XML example
<unit sortField1="First Floor" sortField2="7">
  <employee>
    <id>3040684</id>
    <name>PIFFARETTI Vasco</name>
    <birthdate>20.05.1983</birthdate>
    <beginDate>2012-02-25 08:55:00</beginDate>
    <endDate>9999-12-31 00:00:00</endDate>
    <annotation/>
  </employee>
</unit>

You can tell when the scroll position has changed by handling the propertyChange event coming from the DataGroup:
<s:Application xmlns:fx="http://ns.adobe.com/mxml/2009"
               xmlns:s="library://ns.adobe.com/flex/spark"
               creationComplete="list1.dataGroup.addEventListener('propertyChange', handle)">
    <fx:Script>
        <![CDATA[
            import mx.events.PropertyChangeEvent;
            private function handle(e:PropertyChangeEvent):void {
                if (e.property == 'verticalScrollPosition'){
                    trace('vsp changed');               
                if (e.property == 'horizontalScrollPosition'){
                    trace('hsp changed');               
        ]]>
    </fx:Script>
    <s:List id="list1" width="100" height="50">
        <s:layout>
            <s:VerticalLayout />
        </s:layout>
        <s:dataProvider>
            <s:ArrayList>
                <fx:String>0</fx:String>
                <fx:String>1</fx:String>
                <fx:String>2</fx:String>
                <fx:String>3</fx:String>
                <fx:String>4</fx:String>
                <fx:String>5</fx:String>
                <fx:String>6</fx:String>
                <fx:String>7</fx:String>
            </s:ArrayList>
        </s:dataProvider>
    </s:List>
</s:Application>
You might also want to read and consider voting for http://bugs.adobe.com/jira/browse/SDK-21357

Similar Messages

  • How can I improve performance on my iPad 1. I am having problems with apps closing unexpectedly and also with slow response.

    My iPad 1 has become almost unusable apps crash without warning and the response time is very slow.

    1. Close all inactive apps in the Task Bar. Double-click the Home button and hold apps down for a second or two. Tap the minus sign to close app.
    2. Hold the Sleep and Home button down for about 10 seconds until you see the Apple Logo.

  • With my i phone 4 , the Push notifications doesn't work for apps like (fb viber , whatsapp etc ) it only works for the official apps like message  even when im using the phone, has  this probleme with the iOs 6.0.1 and also with the iOs 6.1

    With my i phone 4 , the Push notifications doesn't work for apps like (fb viber , whatsapp etc ) it only works for the official apps like message  even when im using the phone, has  this probleme with the iOs 6.0.1 and also with the iOs 6.1

    This isn't an issue. Notice the screen prior to the one that shows usage has an iCloud section and a Manage Storage button. For this button to activate ios needs to download a few kb from icloud. Switching back to this screen forces ios to download those few kb.

  • Help configuring Audition with Virtual  Audio Cable and Skype

    I'm using the latest version of Audition, along with Virtual Audio Cable and Skype for my PC (Windows 7).  While I'm able to properly configure my own microphone (Edirol UA-25), to be captured by Audition on track 1, I can't seem to get track 2 configured properly to capture and record.
    I seem to be missing a step.
    Is there anyone that can help me properly configure or offer an alternative that will allow me to record my microphone and the Skype call on two separate tracks?
    Thanks in advance for your expertise!

    Others may have made it work but I've never persuaded Audition to record a mic in one channel and line out (Skype) in the other.  Since Audition it designed to work with a single ASIO audio interface, this makes sense.
    My solution is to use a little utility called the iFree Skype recorder:  Record Skype Calls with iFree Skype Recorder - Your FREE Skype call recorder software
    It works well for me, keeping the outgoing part of the call and the incoming separate for easy editing later.  It works fine with an external audio interface and good mic as long as Skype is set up to work that way.
    The only drawback is that it records in MP3 not wave but, given the quality of most Skype calls, this isn't really a deal breaker.

  • I have two apple ID's, one with all my apps and one with only Mavericks. Will Mavericks update automatically if i'm not logged in to the apple ID I used to download it?

    I have two apple ID's, one with all my apps and one with only Mavericks. Will Mavericks update automatically if i'm not logged in to the apple ID I used to download it?

    Some things are mixed up here, seemingly...
    I seem to have two Apple ID's attached to my e-mail.
    An Apple ID is a valid email address, apparently. How can those be "attached to your email"... what email?
    Facetime will not verify my e-mail address because it is associated with the other account.
    This doesn't make sense. You can register multiple, even non-Apple-ID, email addresses and their aliases with FaceTime.
    So, maybe you can explain your problem better - what you want and the steps you've taken and what you have so far. If something doesn't work, please tell the exact error message, too.

  • TS3474 my i pod is still on a white screen after restoring with the two buttons and also restoring on i tunes and it still has a white screen

    my i pod is still on a white screen after restoring with the two buttons and also restoring on i tunes and it still has a white screen

    I've been struggling with mine all morning with the same issue.
    Mine would not wake up from sleep (will just white screen).
    It will boot using a hard reset (i.e. the power button and volume down button being held down for 8 or so secs). I restored and synced it multiple times but it still has a problem waking up and just just goes to white screen.
    I saw a post suggesting a loose connection which I had my doubts about (as it will wake with hard reset) - bit BINGO! If I wake mine (with index finger) whilst applying pressure to the top of the screen area (with my thumbs) it will wake up. When I become frustrated enough I'll take it apart and see if something has become loose.
    Hope this helps.

  • I can't install ADE on my PC, because as I try to open it a message of error appears to me: The application will be closed. I've already try with different browsers and also with the manual installation, but nothing..

    I can't install ADE on my PC, because as I try to open it a message of error appears to me: The application will be closed. I've already try with different browsers and also with the manual installation, but nothing..

    1
    Close all iWork applications
    2
    Uninstall Keynote; this must be done with an application remover tool to delete the installation properly. Appcleaner is known to work correctly for this purpose, it is free and can be downloaded from here: Appcleaner Download
    3
    empty the trash
    4
    shutdown the Mac and restart. After the start up chime, hold down the shift key until the apple logo appears
    let the Mac complete the start up procedure completely, it will take longer than usual as the hard drive is being repaired
    5
    Reinstall Keynote by logging into the Mac App Store using download / install

  • I have continuously over the last 6 months struggled with syncing my iphone and ipod with itunes  The app continually crashes during the picture import.  AND by the way it takes 10-15 minutes before it even attempts to import photos.  The screen says impo

    I have continuously over the last 6 months struggled with syncing my iphone and ipod with itunes  The app continually crashes during the picture import.  AND by the way it takes 10-15 minutes before it even attempts to import photos.  The screen says importing photoes but doesnt try to optimize or anything for 10 minutes.  I have a 3gs with 16Gb so its not a cheap phone.  I have 10Gb free.  I have 6600 photoes.  This is very frustrating and undermines my confidence in your products.  My ipod is an ipod 4 with 16Gb also.  It does the exact same thing to it.  The last time, I had to import photoes a few at the time and with it taking 10-15 minutes each time for 6600 photos it is a long frustrating process.  But it will import every photo a few at a time.  The error message is just that itunes has stopped working.  no hint as to why. AND of course, my phone is out of use for the entire time.  You guys must not want to believe ur phones are a necessary tool...or maybe you dont want the consumer to believe it is.  I have tried to find solutions on your website as well as through other 3rd party communities.  Ultimately they were of no use.  I stumbled onto my solution by accident since Im a bit of a computer geek...a semi-geek.

    I have this issue too, I went into my Windows event viewer. (should have looked at this a year ago when this started)
    it said this
    Faulting application name: iTunes.exe, version: 11.0.2.26, time stamp: 0x51253247
    Faulting module name: ntdll.dll, version: 6.1.7601.17725, time stamp: 0x4ec49b8f
    Exception code: 0xc0000374
    Fault offset: 0x000ce6c3
    Faulting process id: 0x14d4
    Faulting application start time: 0x01ce194399f166ba
    Faulting application path: C:\Program Files (x86)\iTunes\iTunes.exe
    Faulting module path: C:\Windows\SysWOW64\ntdll.dll
    Report Id: 0eb3c37f-8537-11e2-9351-50465d6737de
    basically whenever I try to sync my ipod touch 4G 64GB it crashes iTunes when it begins the pictures. if im lucky ill get 4-5 on there before it stops responding. its not my system or anything im running win7x64 8GB DDR3 ram (Corsair XMS3) AMD FX Eight core processor.
    It is silly that iTunes cannot add pictures to apple devices. it shatters whatever incline I may have to buy apple products. knda like the Airport Extreem router my dad bought the new firmware, caused my router to not function... why release firmware that breaks a product. -_- <-- off topic but still

  • I am having trouble with the Jpeg icons and also now thumbnails not being visable in bith teh Apple finder and now also Adobe Bridge. Can anyone shed any light on this ?

    I am having trouble with the Jpeg icons and also now thumbnails not being visable in bith teh Apple finder and now also Adobe Bridge. Can anyone shed any light on this ?

    Argh - once again, I find my solution right after posting this. Left out one modification to the SWIG script, now it runs in 29 seconds vs C 16 seconds, I can live with that.

  • Can i use iCloud keychain with my own passwords and not with what is assigned and stored?

    Can i use iCloud keychain with my own passwords and not with what is assigned and stored?

    tammersalem wrote:) <-HDMI-> (HDTV)
    My main concerns are:
    -If I use iTunes on my main computer, will it then be available to Apple TV?
    -If I use Apple TV to download will it be available to my Main computer?
    -Can the Apple TV use a media server for storage over LAN (using NTFS Samab or otherwise)?
    Basically iTunes feeds AppleTv with media either syncing (copying to it) or streaming live.
    Media must be compatible with AppleTV.
    AppleTV requires a proper iTunes instance running - it cannot access a NAS directly.
    If you store media in a folder on a NAS and it's part of the computer iTunes library (just stored on the NAS vs internal/external drive), then when running iTunes makes this content available to AppleTV.
    Data will travel:
    NAS > network > iTunes > network to AppleTV
    As the path is potentially slower than internal/external attached drive > iTunes > network > AppleTV, it may or may not work robustly for streaming.
    If AppleTv is set to sync (it can also stream in this mode), when you purchase direct on AppleTV, the media should sync back to where the itunes library is stored (via iTunes) to keep things in sync and to allow you to backup the media.
    You cannot drag/drop media to/from AppleTv across the network, nor can it directly access storage itself - iTunes is an essential cog in the wheel.
    The majority of commercial 'in-built iTunes media servers' will not work directly with AppleTV as it has to be 'paired' with iTunes by entering a numerical code in iTunes and does not simply see 'shared libraries'.

  • How do I connect TC to a new ethernet and share a new ethernet DSL with a new PC and use with my macbook Pro? I tried and get no internet on the PC or Macbook Pro?

    how do I connect TC to a new ethernet and share a new ethernet DSL with a new PC and use with my macbook Pro? I tried and get no internet on the PC or Macbook Pro?

    Ok.
    I am connected to wi-fi through TC connected to a specific router and is working perfectly and saving data through TM without any issues.
    The TC version is 7.6.1 and am using OS 10.7.3
    The router mode is on Bridge mode and router is connected to TC through USB cable, I suppose for internet access. My Mac is on wi-fi through TC
    I have another location, much further, which recently have been installed with wi-fi through router that has WPA accessibiulity with password, 100% different than the current one.
    Since, I will be most of my time in this new location, I wish to move my TC to this new location, and configure it in similar fashion like what I am having right now.
    Naturally, I do not wish to lose any saved data on the TC.
    Hope I managed to provide enought info.
    Thanks in advance

  • HT1310 when i starst my mac i get a flashing folder with a question mark. i tried rebooting and holding the option button then i get 2 boxes, one with a refresh arrow and one with a forward arrow neither of them seem to do anything. now what

    when i starst my mac i get a flashing folder with a question mark. i tried rebooting and holding the option button then i get 2 boxes, one with a refresh arrow and one with a forward arrow neither of them seem to do anything. now what

    Here is an article that describes what it is supposed to do:
    Startup Manager: How to select a startup volume
    If no Volumes are shown, it is telling you there are no potentailly bootable Volumes attached. That means your boot drive has died or the bootable image on it is unrecognizable.
    What Mac Pro ? by year, GHz, number of processors, screen size?
    What Mac OS X ?

  • I have a MBP 15" with iPhoto 9. When right clicking on icon in dock 3 iPhoto libraries come up; one empty, one with 35,000 photos and one with 30,000 photos.  How can I delete the empty one and merge the other two without getting duplicates?

    I have a MBP 15" with Iphoto 9.  When I right click on icon in dock 3 iPhoto libraries come up; one empty, one with 35,000 photos and one with 30,000 photos.  How can I delete the empty library and merge the other two without getting duplicates?

    You can delete the empty one by dragging it to the trash ( test everything before emptying the trash)
    Merging libraries requires iPhoto Library Manager - http://www.fatcatsoftware.com/iplm/ -  it is the only current solution to merging libraries
    LN

  • Tranforming 0 to False and 1 to true

    Gurus,
    I am using sql query template and getting data  as 0/1 for one column from table.
    I want to show 0 as FALSE and 1 as TRUE in the iGrid.
    I didn't ever use the tranform tab . Do i have to write any xslt for my query??
    Or
    do i have to just change the query to get that simple transformation?
    Any ideas??
    Please help.
    Thanks
    Vansi

    Your best bet is to look at the help documentation for 11.5, there are several predefined xsl examples detailed there, and the wwwroot/Illuminator/Stylesheets directory has several examples for a point of reference.
    The InlineTransform tab is where you would apply this xsl file to your raw query data and it would need to take the Rowsets/Rowset/Row and produce the new desired Rowsets/Rowset/Row results.  This functionality pre-dates BLS, and it will probably be easier for you to use the action blocks to do your transformations.
    Regards,
    Jeremy

  • Help needed with virtual bookshelf - drag and drop between components?

    Hi there,
    Im trying to create a virtual bookshelf, where book spines are individual movie clips that can be dragged and re-ordered on the shelf.  At the moment i can drag the spines to one assigned target, but not any target or 'nudge' the position of the other books along.
    Im sorry if this is a bit vague i'm not that experienced in as3, please feel free to ask any questions and i'll do my best to answer.  Im thinking that an array is necessary which holds the positions, but im not sure how to put it all together!
    Any help greatly appreciated! The code i have so far is:
    import flash.events.MouseEvent;
    import flash.display.MovieClip;
    var dragArray:Array = [red, blue, green, purple, yellow];
    var matchArray:Array = [target1, target2, target3, target4, target5];
    var currentClip:MovieClip;
    var startX:Number;
    var startY:Number;
    for(var i:int = 0; i < dragArray.length; i++) {
    dragArray[i].buttonMode = true;
    dragArray[i].addEventListener(MouseEvent.MOUSE_DOWN, item_onMouseDown);
    matchArray[i].alpha = 0.2;
    function item_onMouseDown(event:MouseEvent):void {
    currentClip = MovieClip(event.currentTarget);
    startX = currentClip.x;
    startY = currentClip.y;
    addChild(currentClip); //bring to the front
    currentClip.startDrag();
    stage.addEventListener(MouseEvent.MOUSE_UP, stage_onMouseUp);
    function stage_onMouseUp(event:MouseEvent):void {
    stage.removeEventListener(MouseEvent.MOUSE_UP, stage_onMouseUp);
    currentClip.stopDrag();
    var index:int = dragArray.indexOf(currentClip);
    var matchClip:MovieClip = MovieClip(matchArray[index]);
    if(matchClip.hitTestPoint(currentClip.x, currentClip.y, true)) {
      //a match was made! position the clip on the matching clip:
      currentClip.x = matchClip.x;
      currentClip.y = matchClip.y;
      //make it not draggable anymore:
      currentClip.removeEventListener(MouseEvent.MOUSE_DOWN, item_onMouseDown);
      currentClip.buttonMode = false;
    } else {
      //match was not made, so send the clip back where it started:
      currentClip.x = startX;
      currentClip.y = startY;

    Morning kglad, thanks for your help yesterday. I tried the code again and still have the same problems - you cant drop over another book and it nudges that book along aswell as the others to the right. Also if you drop a book back in its originally place - sometimes - it creates a gap next to it. The book still only seem happy in their original starting positions!
    Its very close, im continuing to try fiddle with it to get it working, have the whole of today to try and do this so the coffee is on!
    Ive taken some code out that I realise this morning I didnt't need - e.g the code that stops a book being dragged once you have positioned it (they need to be able to be repositioned more than once, and the code that sends a book back to its original position if you didnt reposition it over a target. If this was foolish please tell me! I have a feeling the latter was!
    so the code im trying to get working at the moment is:
    import flash.events.MouseEvent;
    import flash.display.MovieClip;
    var dragArray:Array = [red, blue, green, purple, yellow];
    var matchArray:Array = [target1, target2, target3, target4, target5];
    var currentClip:MovieClip;
    var startX:Number;
    var startY:Number;
    for(var i:int = 0; i < dragArray.length; i++) {
    // REMOVED
    //dragArray[i].buttonMode = true;
    dragArray[i].addEventListener(MouseEvent.MOUSE_DOWN, item_onMouseDown);
    matchArray[i].alpha = 0.2;
    function item_onMouseDown(event:MouseEvent):void {
    currentClip = MovieClip(event.currentTarget);
    startX = currentClip.x;
    startY = currentClip.y;
    addChild(currentClip); //bring to the front
    currentClip.startDrag();
    stage.addEventListener(MouseEvent.MOUSE_UP, stage_onMouseUp);
    function stage_onMouseUp(event:MouseEvent):void {
    stage.removeEventListener(MouseEvent.MOUSE_UP, stage_onMouseUp);
    currentClip.stopDrag();
    var index:int = dragArray.indexOf(currentClip);
    var matchClip:MovieClip = MovieClip(matchArray[index]);
    if(matchClip.hitTestPoint(currentClip.x, currentClip.y, true)) {
      //a match was made against a target:
      currentClip.x = matchClip.x;
      currentClip.y = matchClip.y;
    //REMOVED
    //make it not draggable anymore:
      //currentClip.removeEventListener(MouseEvent.MOUSE_DOWN, item_onMouseDown);
      //currentClip.buttonMode = false;
    for(var i:int=dragArray.indexOf(currentClip)+1;i<dragArray.length;i++){
    dragArray[i].x+=currentClip.width;
      // REMOVED
      //else {
      //match was not made, so send the clip back where it started:
      //currentClip.x = startX;
      //currentClip.y = startY;

Maybe you are looking for

  • How can I sync iPod Mini after hard drive reformat?

    My son has an iPod mini. Recently, we had to have our computer hard drive reformatted and had to reinstall iTunes. When we try to sync the mini, it shows up with all it's songs, but the songs won't update into the library, so the desktop iTunes has n

  • PDF Document is not working

    Hi, We are migrated from xMII 12.0 to MII 14.0 SP04 . We generate PDF document. A html page calls a exacute query which calls a transaction. In the transaction, a PDF Document object, PDF Bar Code object, Delete File object and Image Saver. Delete Fi

  • Sampeling a colour from a photo places in Illy CS4

    Hoping this is a simple one to figure out. In CS3 I would drop a photo into the document and then using the eyedropper I would just sample colours from the photo. CS4 wont sample full stop - pulling my hair out and grinding to a halt on the whole wor

  • Bt Infinity 80/20

    I got Infinity 80/20 at the end of June. For the first 3 weeks i had a rock solid 50/15 actual service with very low single figure pings to test servers. After the first 3 weeks the service became "variable" to say the least. The down speed wanders a

  • Why do my pages turn out black?

    I have attempted to print pages from my iweb.  They turn out black.  Any ideas on why?  And how to get good results in this process? Thanks, jg