added a comment, closes #135
This commit is contained in:
parent
a0cf28ba14
commit
e28b4c7526
1 changed files with 2 additions and 0 deletions
|
@ -29,6 +29,8 @@ ball.onmousedown = function(event) { // (1) start the process
|
||||||
// (2) prepare to moving: make absolute and on top by z-index
|
// (2) prepare to moving: make absolute and on top by z-index
|
||||||
ball.style.position = 'absolute';
|
ball.style.position = 'absolute';
|
||||||
ball.style.zIndex = 1000;
|
ball.style.zIndex = 1000;
|
||||||
|
// move it out of any current parents directly into body
|
||||||
|
// to make it positioned relative to the body
|
||||||
document.body.append(ball);
|
document.body.append(ball);
|
||||||
// ...and put that absolutely positioned ball under the cursor
|
// ...and put that absolutely positioned ball under the cursor
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue