jquery - Dragging a rotated div simultaneously with an image -
i have 2 divs. 1 border, same size of image.
when have image (tweet image, not rotated) works.
when move rotated image (clown image), div moves unwanted (at start drag)
the image not @ same location.
how solve problem css / jquery?
// putting images on screan $("#img1").css({"top": "200px", "left": "100px"}); $("#img1").myrotate(); $("#img2").css({"top": "100px", "left": "300px"}); $("#img2").myrotate(); // rotating image 2 rotateme($("#img2"), 45); rotateme(selecteddiv, 45); // here problem div.draggable({ drag: function() { id = $(this).attr("id").substring(3); var pos = $(this).position(); $("#" + id).css({"top": pos.top + "px", "left": pos.left + "px"}); } });
Comments
Post a Comment