Browse Source

Fixes issue where if context is removed visibilty observers will not properly remove events

pull/4107/head
Jack Lukic 8 years ago
parent
commit
a6238f06c1
1 changed files with 1 additions and 1 deletions
  1. 2
      src/definitions/behaviors/visibility.js

2
src/definitions/behaviors/visibility.js

@ -144,7 +144,7 @@ $.fn.visibility = function(parameters) {
if('MutationObserver' in window) { if('MutationObserver' in window) {
contextObserver = new MutationObserver(module.event.contextChanged); contextObserver = new MutationObserver(module.event.contextChanged);
observer = new MutationObserver(module.event.changed); observer = new MutationObserver(module.event.changed);
contextObserver.observe($context[0], {
contextObserver.observe(document, {
childList : true, childList : true,
subtree : true subtree : true
}); });

Loading…
Cancel
Save