Wierd IE bug with remove()/Safari bug with width()
Hi,
First of all, thanks a lot for a great framework! I've only just begun
using jQuery, but I love it already!
Anyway, I'm developing an object for making lists sortable, and I have
found a wierd bug in IE with remove(). The way I do it is that on
mousedown on a listitem, I clone the listitem, give the clone 0
opacity and insert it into the list right before the element clicked
on, which is then absolutely positioned to follow the mouse. I call
that clone a "dummy", and I move the dummy if you hover other list
items. Then on mouseup, I just insert the positioned listitem before
the dummy, and remove the dummy.
At first, I did this with dummy.remove(), but when I did that the
margin-top of the first listitem disappeared. It only happened in IE
though, Firefox was working just as expected. Just to check, I removed
the dummy with the DOM-method removeChild() instead, and it worked
just as expected, the margin-top was preserved in IE.
A simillar thing happened in Safari on PC, when I was using width(),
the margin-left disappeared, but when i switched to offsetWidth, it
worked just fine. I was calculating the middle of the element by using
element.width() / 2.
I don't know if you want to see my code, or just parts of it?