natuanorg / android-zoom-view

Automatically exported from code.google.com/p/android-zoom-view
BSD 2-Clause "Simplified" License
0 stars 0 forks source link

Drag limits for zoom view content #5

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
1. Set max zoom factor to 4
2. Double click the image to enlarge to maximum
3. Scroll the image inside the videw

Scrolling should be limited to the physical view bounds of the image, so for 
example, if the top of the enlarged image reaches the physical view top zooming 
should stop.

I tried various options, however I could not get any of these solutions working 
with your implementation. Could you provide me with a solution?

http://stackoverflow.com/questions/7532128/how-to-keep-an-image-inside-the-scree
n-limits-while-using-pinch-zoom-and-drag-ge

http://stackoverflow.com/questions/4227451/android-imageview-setting-drag-and-pi
nch-zoom-parameters

Original issue reported on code.google.com by fl.lett...@gmail.com on 4 Sep 2013 at 8:46

GoogleCodeExporter commented 8 years ago
hi
this was a known issue
i just commited a fix which solves this problem, you can checkout new code and 
it should work fine
just remember to set probper bounds to content inside ZoomView! for ImageView 
you should set proper scaling type and set adjustViewBounds=true

Original comment by karooo...@gmail.com on 16 Jan 2014 at 11:06