Jump to content
GreenSock

steve1628

Members
  • Posts

    2
  • Joined

  • Last visited

Everything posted by steve1628

  1. Hi Jack, Thanks for the reply. Basically I drag a handle on a custom slider that I created with Javascript, that slider being inside a div which act as a page. Now when I hide that div and come back to it later by toggling the div visibility, when I re-do the Draggable.create function the drag handle position is that of the old recorded position where I previously left it, it doesn't reset to 0px. I will try the solution you outlined and see if it work. stee
  2. Hi there, First of all I like to say i love your product and have been actively using the AS version along time and when a js version came out, it was like a god set. I have a issue with the Draggable class, basically i am using the class to drag a custom slider. When I then proceed to another section of my web application and then come back to the page which has the slider class there is no way to reset the slider drag handle position back to 0, I have tried making the instances of the draggbable item to null and have even clear the style attr, but for some reason when I recreate new Drag instances the transform matrix data is of the old data this is how I try to get rid of the old instances: for (var i = 0; i < this._draggables.length; i++) { this._draggables.disable(); //disable the instance. this._draggables=null; } $(".drag_handle").attr("style","") this._draggables=null; and this is how I create it this._draggables =Draggable.create("#allocate_people .drag_handle",{type:"x",bounds:$('#allocate_people .drag_handle').parent()}) any suggestion as to what I can do to reset it back to it original position thanks, Steve
×