luster-io / impulse

Dynamic Physics Interactions for the Mobile Web
http://impulse.luster.io
MIT License
1.59k stars 74 forks source link

Dynamic drag boundary #18

Closed mpohl closed 10 years ago

mpohl commented 10 years ago

First, thanks for this nice work! Is it possible to update the boundary used when dragging? I am using impulse to drag the background of an responsive page, so i like to update the boundary on window.resize()

xcoderzach commented 10 years ago

Yep, you can mutate the top, left, bottom, and right properties on the Boundary you create.

boundary.left = newLeft

This should work. However I'm not at my computer so I wasn't able to test.

mpohl commented 10 years ago

Thanks again, this seems to work, maybe since version 0.0.5?