This commit is contained in:
Nicolas Stepien 2012-05-14 18:24:21 +02:00
parent e3b5645726
commit 216a05f9b4
2 changed files with 10 additions and 3 deletions

View File

@ -3120,7 +3120,10 @@
},
add: function(q, id) {
var clonePost, el, i, inline, pathname, root;
root = $.x('ancestor::*[parent::blockquote]', q);
root = q;
while (root.parentNode.nodeName !== 'BLOCKQUOTE') {
root = root.parentNode;
}
if (el = $.id("p" + id)) {
if (/\bop\b/.test(el.className)) {
$.removeClass(el.parentNode, 'qphl');

View File

@ -2402,8 +2402,12 @@ QuoteInline =
@classList.toggle 'inlined'
add: (q, id) ->
root = $.x 'ancestor::*[parent::blockquote]', q
if el = $.id "p#{id}"
# Can't use this because Firefox a shit:
# root = $.x 'ancestor::*[parent::blockquote]', q
root = q
while root.parentNode.nodeName isnt 'BLOCKQUOTE'
root = root.parentNode
if el = $.id "p#{id}"
if /\bop\b/.test el.className
$.removeClass el.parentNode, 'qphl'
else