Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

Chirone

macrumors 6502
Original poster
Mar 2, 2009
279
0
NZ
Not sure how to say this but in my program i have some nsviews which change position when the mouse is dragged on them (click on the view, drag and it follows with the same offset that it had when you clicked on it)

works fine... except for when you drag the mouse really fast back and forward.
eventually the view has a massive offset from the mouse

i've moving the view using the NSEvent's deltaX and deltaY, in one of the apple sample codes (i think it's sketch?) it does the same but it never has this problem.

any idea whats happening?
 

rossipoo

macrumors regular
Jun 7, 2009
109
0
Another way to do it would be to save the location of the starting click, and the original position of the view, then when the mouse is moved, set the window frame to originalPosition + mouseMove - mouseStartClick.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.