aboutsummaryrefslogtreecommitdiffstats
path: root/src/event.js
diff options
context:
space:
mode:
authorColin Snover <github.com@zetafleet.com>2010-12-26 14:28:49 -0600
committerColin Snover <github.com@zetafleet.com>2010-12-26 14:28:49 -0600
commit37d297c67fe3569a5a9d81586e14d4a887df7879 (patch)
treefd1daa71d4e0e084404a41ed653839b9e2696ab7 /src/event.js
parenta939ade9c6d2b42be24031d902c86ec52847c0cc (diff)
downloadjquery-37d297c67fe3569a5a9d81586e14d4a887df7879.tar.gz
jquery-37d297c67fe3569a5a9d81586e14d4a887df7879.zip
Clearing event handlers on unload is no longer necessary in any version of IE. This issue causing memory leaks between pages was fixed in MS07-033.
Diffstat (limited to 'src/event.js')
-rw-r--r--src/event.js17
1 files changed, 0 insertions, 17 deletions
diff --git a/src/event.js b/src/event.js
index 22c958576..b66cfab6d 100644
--- a/src/event.js
+++ b/src/event.js
@@ -1177,21 +1177,4 @@ jQuery.each( ("blur focus focusin focusout load resize scroll unload click dblcl
}
});
-// Prevent memory leaks in IE
-// Window isn't included so as not to unbind existing unload events
-// More info:
-// - http://isaacschlueter.com/2006/10/msie-memory-leaks/
-if ( window.attachEvent && !window.addEventListener ) {
- jQuery(window).bind("unload", function() {
- for ( var id in jQuery.cache ) {
- if ( jQuery.cache[ id ].handle ) {
- // Try/Catch is to handle iframes being unloaded, see #4280
- try {
- jQuery.event.remove( jQuery.cache[ id ].handle.elem );
- } catch(e) {}
- }
- }
- });
-}
-
})( jQuery );