9 Replies Latest reply on Jan 11, 2012 7:09 AM by kkudiksx

    stuck in ListBase.setSelectionDataLoop

    eprevot123

      Sometimes when I set the selectedItem of a Tree after changing its dataprovider, the application freezes :

      when I debug and look at the collectionIterator of the Tree, it still has information of the old dataprovider, and the ListBase.setSelectionDataLoop enters an infinite loop.

       

      I tried to set the selectedItem in a callLater, and call :

      tree.invalidateList();
      tree.invalidateSize();
      tree.invalidateDisplayList();
      tree.validateNow();

       

      and it works in most of the cases, but in some cases my application still freezes.

       

      Do you know how can I be sure to update my Tree before I set the selectedItem ?