darsain / sly

JavaScript library for one-directional scrolling with item based navigation support.
http://darsa.in/sly
2.87k stars 496 forks source link

How do I set up to determine the length of release #139

Closed evolutionjay closed 10 years ago

evolutionjay commented 10 years ago

asda

Look at the picture, I want to configure the length of this judgment. Plz tell me

darsain commented 10 years ago

Sly doesn't expose this, but why won't you just retrieve it from the element itself?

var handlePosition = parseInt(handleElement.style.left, 10);

In case you are actually asking for the dragging length translated to scrollbar position (I'm having trouble comprehending your request), than such a thing is really not exposed anywhere.

If you start having really specific requests like this, it is usually a good idea to create your own solution instead of relying on open source libraries that obviously can't cater to every possible need of every developer on a planet :)

I'm closing this as it is a general question and not an issue with Sly. If you have more comments post them here, don't create a new issue please.