Fix tombstone bug and an SVG-Edit regression

Bug reported by Andrew Stacey
This commit is contained in:
Jacques Distler 2011-09-30 00:07:53 -05:00
parent e749ee1e4b
commit 2d9cc8bf4d
3 changed files with 10 additions and 3 deletions

View file

@ -42,9 +42,15 @@ function fixRunIn() {
});
// add tombstone to proof, since gecko doesn't support :last-child properly
$$('div.proof').each(function(element) {
var l = element.childElements().length -1;
var el = element.childElements()[element.childElements().length-1];
var span = new Element('span').update('\u00a0\u00a0\u25ae');
element.childElements()[l].insert(span);
if (el.match('p')) {
el.insert(span);
} else {
var par = new Element('p').update(span);
par.addClassName('tombstone');
element.appendChild(par);
}
});
}