mirror of
https://github.com/DataTables/DataTables.git
synced 2025-02-21 19:54:15 +01:00
Fix: Don't redraw the table for page change when no change needed
- If you were to click the 'previous' button when on the first page, the table would redraw - that's the easiest manifestation of this bug to see. There is no need to redraw the table when the paging hasn't changed, so don't. - This fixes DataTables/DataTables #304
This commit is contained in:
parent
22023595e8
commit
950110e1fd
@ -1 +1 @@
|
|||||||
1d90761f159e7ff2b4453ce6ce246a79babdc426
|
3911b8970e90370e8edf4f093f1afcbc2feb859b
|
||||||
|
8
media/js/jquery.dataTables.js
vendored
8
media/js/jquery.dataTables.js
vendored
@ -3322,10 +3322,12 @@
|
|||||||
var changed = settings._iDisplayStart !== start;
|
var changed = settings._iDisplayStart !== start;
|
||||||
settings._iDisplayStart = start;
|
settings._iDisplayStart = start;
|
||||||
|
|
||||||
_fnCallbackFire( settings, null, 'page', [settings] );
|
if ( changed ) {
|
||||||
|
_fnCallbackFire( settings, null, 'page', [settings] );
|
||||||
|
|
||||||
if ( redraw ) {
|
if ( redraw ) {
|
||||||
_fnDraw( settings );
|
_fnDraw( settings );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return changed;
|
return changed;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user