override protected function measure():void { super.measure(); const tocItem:TocItem = TocItem(data); // Add space for the checkbox and gaps if (isNaN(explicitWidth) && !isNaN(measuredWidth)) { var w:Number = measuredWidth; if(tocItem) if(w < tocItem.tocMinWidth) w = tocItem.tocMinWidth - 20; if (_vbox && _vbox.numChildren > 0) w += _vbox.measuredWidth; measuredWidth = w; } if (!isNaN(measuredHeight)) { var h:Number = measuredHeight + 5; if(_vbox && _vbox.numChildren > 0) h += _vbox.getExplicitOrMeasuredHeight(); measuredHeight = h; } }