Permalink
Browse files

Dev: Get the library size back under the target 70000 bytes. Its a bi…

…t of a cheap shoot this one, but every little helps!
  • Loading branch information...
1 parent a0ebd9f commit 4a4b6f6d5828ccc3a76636418010b3ec497e4ae2 @DataTables DataTables committed Jan 31, 2012
Showing with 14 additions and 12 deletions.
  1. +7 −6 media/js/jquery.dataTables.js
  2. +7 −6 media/src/api/api.methods.js
@@ -5583,6 +5583,7 @@
this.fnIsOpen = function( nTr )
{
var oSettings = _fnSettingsFromNode( this[DataTable.ext.iApiIndex] );
+ var aoOpenRows = oSettings.aoOpenRows;
for ( var i=0 ; i<oSettings.aoOpenRows.length ; i++ )
{
@@ -5714,11 +5715,11 @@
{
var oSettings = _fnSettingsFromNode( this[DataTable.ext.iApiIndex] );
var i, iLen;
- var iColumns = oSettings.aoColumns.length;
+ var aoColumns = oSettings.aoColumns;
var nTd, nCell, anTrs, jqChildren, bAppend, iBefore;
/* No point in doing anything if we are requesting what is already true */
- if ( oSettings.aoColumns[iCol].bVisible == bShow )
+ if ( aoColumns[iCol].bVisible == bShow )
{
return;
}
@@ -5729,7 +5730,7 @@
var iInsert = 0;
for ( i=0 ; i<iCol ; i++ )
{
- if ( oSettings.aoColumns[i].bVisible )
+ if ( aoColumns[i].bVisible )
{
iInsert++;
}
@@ -5741,9 +5742,9 @@
/* Which coloumn should we be inserting before? */
if ( !bAppend )
{
- for ( i=iCol ; i<iColumns ; i++ )
+ for ( i=iCol ; i<aoColumns.length ; i++ )
{
- if ( oSettings.aoColumns[i].bVisible )
+ if ( aoColumns[i].bVisible )
{
iBefore = i;
break;
@@ -5785,7 +5786,7 @@
}
/* Clear to set the visible flag */
- oSettings.aoColumns[iCol].bVisible = bShow;
+ aoColumns[iCol].bVisible = bShow;
/* Redraw the header and footer based on the new column visibility */
_fnDrawHead( oSettings, oSettings.aoHeader );
@@ -829,6 +829,7 @@ this.fnGetPosition = function( nNode )
this.fnIsOpen = function( nTr )
{
var oSettings = _fnSettingsFromNode( this[DataTable.ext.iApiIndex] );
+ var aoOpenRows = oSettings.aoOpenRows;
for ( var i=0 ; i<oSettings.aoOpenRows.length ; i++ )
{
@@ -960,11 +961,11 @@ this.fnSetColumnVis = function ( iCol, bShow, bRedraw )
{
var oSettings = _fnSettingsFromNode( this[DataTable.ext.iApiIndex] );
var i, iLen;
- var iColumns = oSettings.aoColumns.length;
+ var aoColumns = oSettings.aoColumns;
var nTd, nCell, anTrs, jqChildren, bAppend, iBefore;
/* No point in doing anything if we are requesting what is already true */
- if ( oSettings.aoColumns[iCol].bVisible == bShow )
+ if ( aoColumns[iCol].bVisible == bShow )
{
return;
}
@@ -975,7 +976,7 @@ this.fnSetColumnVis = function ( iCol, bShow, bRedraw )
var iInsert = 0;
for ( i=0 ; i<iCol ; i++ )
{
- if ( oSettings.aoColumns[i].bVisible )
+ if ( aoColumns[i].bVisible )
{
iInsert++;
}
@@ -987,9 +988,9 @@ this.fnSetColumnVis = function ( iCol, bShow, bRedraw )
/* Which coloumn should we be inserting before? */
if ( !bAppend )
{
- for ( i=iCol ; i<iColumns ; i++ )
+ for ( i=iCol ; i<aoColumns.length ; i++ )
{
- if ( oSettings.aoColumns[i].bVisible )
+ if ( aoColumns[i].bVisible )
{
iBefore = i;
break;
@@ -1031,7 +1032,7 @@ this.fnSetColumnVis = function ( iCol, bShow, bRedraw )
}
/* Clear to set the visible flag */
- oSettings.aoColumns[iCol].bVisible = bShow;
+ aoColumns[iCol].bVisible = bShow;
/* Redraw the header and footer based on the new column visibility */
_fnDrawHead( oSettings, oSettings.aoHeader );

0 comments on commit 4a4b6f6

Please sign in to comment.