From 6a4587ace91189585976885b489d3e85eb51ee98 Mon Sep 17 00:00:00 2001 From: Robert Konigsberg Date: Tue, 17 Apr 2012 14:56:48 -0400 Subject: [PATCH] Tracking all event registrations, and deallocating them en masse makes destroy() retain much less memory. e.g. in a simple case creating and destoying the canonical demo, retains 10K less data upon destroy. --- auto_tests/misc/local.html | 39 ++++++++++++++++++++------------------- dygraph-canvas.js | 8 ++++---- dygraph-range-selector.js | 26 +++++++++++++------------- dygraph-utils.js | 5 +++-- dygraph.js | 43 ++++++++++++++++++++++++++----------------- 5 files changed, 66 insertions(+), 55 deletions(-) diff --git a/auto_tests/misc/local.html b/auto_tests/misc/local.html index 6db0207..0af3cff 100644 --- a/auto_tests/misc/local.html +++ b/auto_tests/misc/local.html @@ -15,33 +15,34 @@ - - - + - - + + + + + + + + + + + + + + + + + + - - - - - - - - - - - + - - -