Code cleanup and fixes
This commit is contained in:
parent
3eb32b25e1
commit
4ffb7be6ce
10
index.html
10
index.html
@ -322,13 +322,11 @@ h1{
|
|||||||
},
|
},
|
||||||
slide: function(event){
|
slide: function(event){
|
||||||
event.preventDefault();
|
event.preventDefault();
|
||||||
newPosition = {
|
var x = slider.startingPagePosition.x + (slider.startingMousePostition.x - event.clientX);
|
||||||
x: slider.startingPagePosition.x + (slider.startingMousePostition.x - event.clientX),
|
var y = slider.startingPagePosition.y + (slider.startingMousePostition.y - event.clientY);
|
||||||
y: slider.startingPagePosition.y + (slider.startingMousePostition.y - event.clientY)
|
window.scrollTo(x, y);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
window.scrollTo(newPosition.x, newPosition.y);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
life.start();
|
life.start();
|
||||||
slider.init();
|
slider.init();
|
||||||
|
Loading…
Reference in New Issue
Block a user