Shouldn't You check for friction = 0 ? http://jsfiddle.net/d9wSc/1/
On Sep 2, 8:56 am, Arian Stolwijk <[email protected]> wrote: > http://mootools.net/demos/?demo=Drag.Scroll > > On Fri, Sep 2, 2011 at 2:36 AM, Graham Warrender <[email protected] > > > > > > > > > wrote: > > Have a look at the google map API! > >http://garnerslaw.co.uk/ > > Check this website out and look at the Get in touch page. > > any questions mail me at [email protected] > > > On 2 Sep 2011, at 01:20, Aaron Newton wrote: > > > In a nutshell, you have to keep track of a brief history of drag position > > over time so you can calculate the velocity if you want that kind of "flick" > > at the end where it keeps going for a short period of time. The way you do > > this is when the user starts dragging, you start a periodical that logs the > > last 3 or 4 positions of the map every 15 milliseconds or so. When the user > > stops dragging, you figure out how far they were away 45 milliseconds ago > > and extrapolate their direction and velocity and then use an Fx instance to > > transition to where it should end. > > > I recently coded a MooTools version of this demo for a client: > > >http://www.apple.com/html5/showcase/threesixty/ > > > But I can't share the code. You can go look at the source of that example > > and see how it's done though. > > > On Thu, Sep 1, 2011 at 5:01 PM, KevinA <[email protected]> wrote: > > >> Hello, > > >> I have been grinding my map class for a long time now, trying to get a > >> drag effect like we see on google maps. > > >> Basically Id like the user to drag and move a map and when they let > >> go, the map will keep sliding a bit depending on how fast they dragged > >> it (just like Google Maps) > > >> Is this possible just using Mootols or am I going to have to use some > >> custom JS alongside the MT drag classes? > > >> Thank you
