TableTools Destroy? Memory leaks
TableTools Destroy? Memory leaks
ellipsis
Posts: 23Questions: 0Answers: 0
On our pages we destroy the Table and I ran into some memory problems, to extend the closed thread:
https://www.datatables.net/forums/discussion/11349/destroy-zeroclipboard-clients-to-prevent-error-when-reinitializing-multiple-times/p1
I modified some code, but still wonder how I should unbind the events, please help!
Changes to TableTools.js:
Add the following directly above the "Private Methods" comment block. (starting line 567 in my copy)
[code]
"fnDestroy": function () {
var flash = ZeroClipboard_TableTools;
for (var inst in flash.clients) {
flash.clients[parseInt(inst, 10)].destroy();
delete flash.clients[parseInt(inst, 10)];
}
flash = null;
// remove TableTool instance
var nr_instancePos = null;
var nr_instances = TableTools._aInstances.length;
for ( var i=0 ; i
https://www.datatables.net/forums/discussion/11349/destroy-zeroclipboard-clients-to-prevent-error-when-reinitializing-multiple-times/p1
I modified some code, but still wonder how I should unbind the events, please help!
Changes to TableTools.js:
Add the following directly above the "Private Methods" comment block. (starting line 567 in my copy)
[code]
"fnDestroy": function () {
var flash = ZeroClipboard_TableTools;
for (var inst in flash.clients) {
flash.clients[parseInt(inst, 10)].destroy();
delete flash.clients[parseInt(inst, 10)];
}
flash = null;
// remove TableTool instance
var nr_instancePos = null;
var nr_instances = TableTools._aInstances.length;
for ( var i=0 ; i
This discussion has been closed.
Replies