From 61243ab9ecb8fa432d2eda956cee042fc6a64827 Mon Sep 17 00:00:00 2001 From: James Campos Date: Mon, 2 May 2011 23:26:53 -0700 Subject: [PATCH] herp, stopPropagation --- 4chan_x.js | 8 ++++---- script.coffee | 8 ++++---- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/4chan_x.js b/4chan_x.js index 7044f887a..2f833f960 100644 --- a/4chan_x.js +++ b/4chan_x.js @@ -1205,9 +1205,9 @@ init: function() { var node; node = $('form[name=delform] > *:not([id])'); - $.bind(d.body, threading.preventDefault); + $.bind(d, 'DOMNodeInserted', threading.stopPropagation); threading.thread(node); - return $.unbind(d.body, threading.preventDefault); + return $.unbind(d, 'DOMNodeInserted', threading.stopPropagation); }, thread: function(node) { var div, op; @@ -1235,8 +1235,8 @@ return threading.thread(node); } }, - preventDefault: function(e) { - return e.preventDefault(); + stopPropagation: function(e) { + return e.stopPropagation(); } }; threadHiding = { diff --git a/script.coffee b/script.coffee index 02e591a7b..c535fdc85 100644 --- a/script.coffee +++ b/script.coffee @@ -934,9 +934,9 @@ threading = # don't thread image controls node = $ 'form[name=delform] > *:not([id])' # don't confuse other scripts *cough*/b/ackwash*cough* - $.bind d.body, threading.preventDefault + $.bind d, 'DOMNodeInserted', threading.stopPropagation threading.thread node - $.unbind d.body, threading.preventDefault + $.unbind d, 'DOMNodeInserted', threading.stopPropagation thread: (node) -> op = $.el 'div', @@ -963,8 +963,8 @@ threading = unless node.align or node.nodeName is 'CENTER' threading.thread node - preventDefault: (e) -> - e.preventDefault() + stopPropagation: (e) -> + e.stopPropagation() threadHiding = init: ->