             return findIndexAt(y, gap, g, i0, Math.max(i0, index-1));
         else 
             return findIndexAt(y, gap, g, Math.min(index+1, i1), i1);
-	}   
+	} 
+	
+   /**
+    *  Returns the index of the first non-null includeInLayout item, 
+    *  beginning with the item at index i.  
+    * 
+    *  Returns -1 if no such item can be found.
+    *  
+    *  @private
+    */
+    private static function findLayoutItemIndex(g:GroupBase, i:int, dir:int):int
+    {
+        var n:int = g.numLayoutItems;
+        while((i >= 0) && (i < n))
+        {
+           var item:ILayoutItem = g.getLayoutItemAt(i);
+           if (item && item.includeInLayout)
+           {
+               return i;      
+           }
+           i += dir;
+        }
+        return -1;
+    }
 
    /**
     *  Updates the first,lastIndexInView properties per the new

                lastIndex = lastIndexInView;
                if (inView(lastIndex) >= 1)
                   lastIndex = Math.min(maxIndex, lastIndex + 1);
                itemR = itemScan(g, lastIndex, +1);
                break;
            }
        }
    
        switch (unit)
        {
            case Keyboard.UP:
                return (itemR) ? Math.max(minDelta, itemR.top - scrollR.top) : 0;
                
            case Keyboard.DOWN:
            	return (itemR) ? Math.min(maxDelta, itemR.bottom - scrollR.bottom) : 0;
                
            case Keyboard.PAGE_UP:
                return (itemR) ? Math.max(minDelta, itemR.bottom - scrollR.bottom) : 0;
                
            case Keyboard.PAGE_DOWN:
                return (itemR) ? Math.min(maxDelta, itemR.top - scrollR.y) : 0;
                                
            default:
                return super.verticalScrollPositionDelta(unit);
        }       
    }     
        
    private function variableRowHeightMeasure(layoutTarget:GroupBase):void

        if (!g)
            return;     

        var n:int = g.numLayoutItems - 1;
        if (n < 0) 
        {
            setIndexInView(-1, -1);
            return;
        }
        
        var scrollR:Rectangle = g.scrollRect;
        if (!scrollR)
        {
            setIndexInView(0, n);
            return;    
        }
        
        var y0:Number = scrollR.top;
        var y1:Number = scrollR.bottom;
        if (y1 <= y0)
        {
            setIndexInView(-1, -1);
            return;
        }

        // TBD: special case for variableRowHeight false

        var i0:int = findIndexAt(y0 + gap, gap, g, 0, n);
        var i1:int = findIndexAt(y1, gap, g, 0, n);

        // Special case: no item overlaps y0, is index 0 visible?
        if (i0 == -1)
        {   
            var index0:int = findLayoutItemIndex(g, 0, +1);
            if (index0 != -1)
            {
                var item0:ILayoutItem = g.getLayoutItemAt(index0); 
                var p0:Point = item0.actualPosition;
                var s0:Point = item0.actualSize;                 
                if ((p0.y < y1) && ((p0.y + s0.y) > y0))
                    i0 = index0;
            }
        }

        // Special case: no item overlaps y1, is index n visible?
        if (i1 == -1)
        {
            var index1:int = findLayoutItemIndex(g, n, -1);
            if (index1 != -1)
            {
                var item1:ILayoutItem = g.getLayoutItemAt(index1); 
                var p1:Point = item1.actualPosition;
                var s1:Point = item1.actualSize;                 
                if ((p1.y < y1) && ((p1.y + s1.y) > y0))
                    i1 = index1;
            }
        }   

        setIndexInView(i0, i1);
    }
    
   /**
