mirror of
https://github.com/DataTables/DataTables.git
synced 2024-11-29 11:24:10 +01:00
Fix: It appears that the latest Webkit browsers have changed their scrolling behaviour slightly, which is causing the unit tests to fail. Basically the 'scroll' event is being fired when the infinite scrolling table is having data written to it (i.e the scroll changes - so its kind of fair enough!), so add a check to only load the first set of data when there is no scrolling applied.
This commit is contained in:
parent
6a7a7151b8
commit
9dc702329d
2
media/js/jquery.dataTables.js
vendored
2
media/js/jquery.dataTables.js
vendored
@ -2958,7 +2958,7 @@
|
||||
{
|
||||
$(nScrollBody).scroll( function() {
|
||||
/* Use a blocker to stop scrolling from loading more data while other data is still loading */
|
||||
if ( !oSettings.bDrawing )
|
||||
if ( !oSettings.bDrawing && $(this).scrollTop() !== 0 )
|
||||
{
|
||||
/* Check if we should load the next data set */
|
||||
if ( $(this).scrollTop() + $(this).height() >
|
||||
|
@ -138,7 +138,7 @@ function _fnFeatureHtmlTable ( oSettings )
|
||||
{
|
||||
$(nScrollBody).scroll( function() {
|
||||
/* Use a blocker to stop scrolling from loading more data while other data is still loading */
|
||||
if ( !oSettings.bDrawing )
|
||||
if ( !oSettings.bDrawing && $(this).scrollTop() !== 0 )
|
||||
{
|
||||
/* Check if we should load the next data set */
|
||||
if ( $(this).scrollTop() + $(this).height() >
|
||||
|
Loading…
Reference in New Issue
Block a user