dist/jquery.floatThead.js
function calculateScrollBarSize(){ //this should happen after the floating table has been positioned
        if($scrollContainer.length){
          if(opts.support && opts.support.perfectScrollbar && $scrollContainer.data().perfectScrollbar){
            scrollbarOffset = {horizontal:0, vertical:0};
          } else {
            if($scrollContainer.css('overflow-x') == 'scroll'){
              scrollbarOffset.horizontal = scrollbarWidth;
            } else {
              var sw = $scrollContainer.width(), tw = tableWidth($table, $fthCells);
              var offsetv = sh < th ? scrollbarWidth : 0;
              scrollbarOffset.horizontal = sw - offsetv < tw ? scrollbarWidth : 0;
            }
            if($scrollContainer.css('overflow-y') == 'scroll'){
              scrollbarOffset.vertical = scrollbarWidth;
            } else {
              var sh = $scrollContainer.height(), th = $table.height();
              var offseth = sw < tw ? scrollbarWidth : 0;
              scrollbarOffset.vertical = sh - offseth < th ? scrollbarWidth : 0;
            }
          }
        }
      }
function calculateScrollBarSize(){ //this should happen after the floating table has been positioned
        if($scrollContainer.length){
          if(opts.support && opts.support.perfectScrollbar && $scrollContainer.data().perfectScrollbar){
            scrollbarOffset = {horizontal:0, vertical:0};
          } else {
            if($scrollContainer.css('overflow-x') == 'scroll'){
              scrollbarOffset.horizontal = scrollbarWidth;
            } else {
              var sw = $scrollContainer.width(), tw = tableWidth($table, $fthCells);
              var offsetv = sh < th ? scrollbarWidth : 0;
              scrollbarOffset.horizontal = sw - offsetv < tw ? scrollbarWidth : 0;
            }
            if($scrollContainer.css('overflow-y') == 'scroll'){
              scrollbarOffset.vertical = scrollbarWidth;
            } else {
              var sh = $scrollContainer.height(), th = $table.height();
              var offseth = sw < tw ? scrollbarWidth : 0;
              scrollbarOffset.vertical = sh - offseth < th ? scrollbarWidth : 0;
            }
          }
        }
      }
function calculateScrollBarSize ( ) { //this should happen after the floating table has been positioned if ( $scrollContainer . length ) { if ( opts . support && opts . support . perfectScrollbar && $scrollContainer . data ( ) . perfectScrollbar ) { scrollbarOffset = { horizontal : 0 , vertical : 0 } ; } else { if ( $scrollContainer . css ( 'overflow-x' ) == 'scroll' ) { scrollbarOffset . horizontal = scrollbarWidth ; } else { var sw = $scrollContainer . width ( ) , tw = tableWidth ( $table , $fthCells ) ; var offsetv = sh < th ? scrollbarWidth : 0 ; scrollbarOffset . horizontal = sw - offsetv < tw ? scrollbarWidth : 0 ; } if ( $scrollContainer . css ( 'overflow-y' ) == 'scroll' ) { scrollbarOffset . vertical = scrollbarWidth ; } else { var sh = $scrollContainer . height ( ) , th = $table . height ( ) ; var offseth = sw < tw ? scrollbarWidth : 0 ; scrollbarOffset . vertical = sh - offseth < th ? scrollbarWidth : 0 ; } } } }
checks if THIS table has scrollbars, and finds their widths
checks if THIS table has scrollbars and finds their widths