Copy link to clipboard
Copied
basically I am moving an object out of the scroll pane and to a new parent myblank3all but if I am scrolled down the re-parent no longer holds the same y so when I drag the object out of the scroll pane its y is different and gets further off as I go down. When I scroll down and stop every object in the scrollpane is the same distance off. so I think if I could get the value of the top y or bottom y of the scrollpane but it has to be relative to the scrollpanes symbol that it holds then I could figure it out
function fl_drag(event: MouseEvent): void {
myblank3all = new MovieClip()
myblank3all.addChild(event.currentTarget.parent)
myblank3all.y = myblank3all.y + some number
myblank3all.startDrag()
}
you can use the verticalScrollPosition to get the y of the object in the scrollpane but you probably just want to reposition at about the same y as the scrollpane, don't you?
or, even better, use the mouseY.
Copy link to clipboard
Copied
you can use the verticalScrollPosition to get the y of the object in the scrollpane but you probably just want to reposition at about the same y as the scrollpane, don't you?
or, even better, use the mouseY.
Copy link to clipboard
Copied
I was working with mouseY it didn't seem to help but yea I want re-positioned to stay in the same spot. I will play around more with all your suggestions and see if I can figure it out.
Copy link to clipboard
Copied
thank you very much verticalScrollPostion worked perfect
Copy link to clipboard
Copied
you're welcome.
Find more inspiration, events, and resources on the new Adobe Community
Explore Now