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

                for (index = startIndex; index <= endIndex; index++)
                {
                    elt = layoutTarget.getVirtualElementAt(index);
                    w = calculateElementWidth(elt, targetWidth, containerWidth);
                    x = calculateElementX(elt, w, containerWidth);
                    elt.setLayoutBoundsSize(w, elt.getLayoutBoundsHeight());         
                    elt.setLayoutBoundsPosition(x, elt.getLayoutBoundsY());
                }
            }

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

    /**
