DOM manipulation - setting the height and top in onMouseDown has flakey results

2013-01-07 Thread jkenoyer
We are trying to resize a DOM Div element on the mouse down event by setting the element top and height attribute. This seems to randomly set one or the other or sometimes both. The result is as the user drags the mouse the div keeps flicking and changing size. We tried setting one of the

Re: DOM manipulation - setting the height and top in onMouseDown has flakey results

2013-01-07 Thread emurmur
I don't know exactly what your code looks like, but generally, you can listen for the mousedown on the target div, but the mousemove and mouseup you may want to listen on the body element or some enclosing parent div, because you are constantly moving the mouse out of the div. Also, make sure