         var vsb:ScrollBar = getScroller().verticalScrollBar;  
         return (w >= vsb.getPreferredBoundsWidth()) && (h >= vsb.getMinBoundsHeight());
     }
-        
+
     /**
      * @private
      *  Computes the union of the preferred size of the visible 

                break;
        }
        
        if (showHSB)
            measuredH += Math.max(minViewportInset, hsb.getPreferredBoundsHeight());
        else
            measuredH += minViewportInset;

        if (showVSB)
            measuredW += Math.max(minViewportInset, vsb.getPreferredBoundsWidth());
        else
            measuredW += minViewportInset;

        // The measured size of the viewport is just its preferredBounds, except:
        // don't give up space if doing so would make an auto scrollbar visible.

                vsbVisible = false;
        }

        // Reset the viewport's width,height to account for the visible scrollbars, unless
        // the viewport's size was explicitly set, then we just use that. 
        
        if (isNaN(explicitViewportW))
            viewportW = w - ((vsbVisible) ? (minViewportInset + vsbRequiredWidth()) : (minViewportInset * 2));
        else 
            viewportW = explicitViewportW;
        
        if (isNaN(explicitViewportH))
            viewportH = h - ((hsbVisible) ? (minViewportInset + hsbRequiredHeight()) : (minViewportInset * 2));
        else 
            viewportH = explicitViewportH;

        // If the scrollBarPolicy is auto, and we're only showing one scrollbar, 
        // the viewport may have shrunk enough to require showing the other one.
        
        var hsbIsDependent:Boolean = false;
        var vsbIsDependent:Boolean = false;
    
        if (vsbVisible && !hsbVisible && hAuto && (contentW > viewportW))
            hsbVisible = hsbIsDependent = true;
        else if (!vsbVisible && hsbVisible && vAuto && (contentH > viewportH))
            vsbVisible = vsbIsDependent = true;

        // If the HSB doesn't fit, hide it and give the space back.   Likewise for VSB.
        // If both scrollbars are supposed to be visible but they don't both fit, 
        // then prefer to show the "non-dependent" auto scrollbar if we added the second
        // "dependent" auto scrollbar because of the space consumed by the first.
        
        if (hsbVisible && vsbVisible) 
        {
            if (hsbFits(w, h) && vsbFits(w, h))
            {
                // Both scrollbars fit, we're done.
            }
            else if (!hsbFits(w, h, false) && !vsbFits(w, h, false))
            {
                // Neither scrollbar would fit, even if the other scrollbar wasn't visible.
                hsbVisible = false;
                vsbVisible = false;
            }
            else
            {
                // Only one of the scrollbars will fit.  If we're showing a second "dependent"
                // auto scrollbar because the first scrollbar consumed enough space to
                // require it, if the first scrollbar doesn't fit, don't show either of them.

                if (hsbIsDependent)
                {
                    if (vsbFits(w, h, false))  // VSB will fit if HSB isn't shown   
                        hsbVisible = false;
                    else 
                        vsbVisible = hsbVisible = false;
  
                }
                else if (vsbIsDependent)
                {
                    if (hsbFits(w, h, false)) // HSB will fit if VSB isn't shown
                        vsbVisible = false;
                    else
                        hsbVisible = vsbVisible = false; 
                }
                else if (vsbFits(w, h, false)) // VSB will fit if HSB isn't shown
                    hsbVisible = false;
                else // hsbFits(w, h, false)   // HSB will fit if VSB isn't shown
                    vsbVisible = false;
            }
        }
        else if (hsbVisible && !hsbFits(w, h))  // just trying to show HSB, but it doesn't fit
            hsbVisible = false;
        else if (vsbVisible && !vsbFits(w, h))  // just trying to show VSB, but it doesn't fit
            vsbVisible = false;
        
        // Reset the viewport's width,height to account for the visible scrollbars, unless
        // the viewport's size was explicitly set, then we just use that.
        
        if (isNaN(explicitViewportW))
            viewportW = w - ((vsbVisible) ? (minViewportInset + vsbRequiredWidth()) : (minViewportInset * 2));
        else 
            viewportW = explicitViewportW;

        if (isNaN(explicitViewportH))
            viewportH = h - ((hsbVisible) ? (minViewportInset + hsbRequiredHeight()) : (minViewportInset * 2));
        else 
            viewportH = explicitViewportH;
        
        // Layout the viewport and scrollbars.

        if (viewport)
        {
