      */
      override public function elementAdded(index:int):void
      {
-         if (useVirtualLayout)
-            llv.insert(index);
+         if ((index >= 0) && useVirtualLayout)
+            llv.insert(index);  // insert index parameter is uint
      }
 
     /**

     */
     override public function elementRemoved(index:int):void
     {
        if (useVirtualLayout)
            llv.remove(index);
     }     

    /**

                for (index = startIndex; index <= endIndex; index++)
                {
                    elt = layoutTarget.getVirtualElementAt(index);
                    h = calculateElementHeight(elt, targetHeight, containerHeight); // can be NaN
                    elt.setLayoutBoundsSize(elt.getLayoutBoundsWidth(), h);
                    h = elt.getLayoutBoundsHeight();
                    y = calculateElementY(elt, h, containerHeight);
                    elt.setLayoutBoundsPosition(elt.getLayoutBoundsX(), y);
                }
             }
