Skip to content

How to limit the movement of the image #2

Description

@Cayan

Were you able to achieve this? I've spent half my sunday on it and nothing so far :(

I've studied a few libraries that implement this feature and I wasn't able to properly implement it.

An example of working one: http://jsfiddle.net/d3wxP/1/

Something that really increases the difficult of this task is the number of variables. From the example above to my case I have some extra variables like the density of the screen the image's origin and the image size (most of the times equal to the screen width).

Another example that helped a bit: https://github.com/PeterStaev/nativescript-image-swipe/blob/master/image-swipe.android.ts

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions