ScrollViews and touchmove events...
Hey guys,
I'm building an application where users can move images around and resize them. To do this, I've got an ImageView inside of a ScrollView. When it was just an ImageView, my touchmove event to center it worked fine. Now that it's inside of a ScrollView, it moves slightly, then nothing.
Any ideas what I'm doing wrong? Could the ScrollView's auto content sizing be causing problems or something?
Any advice on moving a ScrollView around would be appreciated. Thanks guys.
6 Answers
-
sounds like you're doing something similar to me.
and scrollview was my first thought for being able to resize images.so yes, +1. hopefully someone has an answer :)
-
Why are you using the scroll view - is this so that you can move beyond the bounds of the screen?
The problem is that image view and scroll view will fight each other for the touch events.
We should be able to come up with another way of doing this if i understand the use case a little more detail.
-
I don't know the best way to handle image scaling on ipod or ipad. However, on android if you toss out the scrollview and use imageView alone with the "canScale" option set to true. You get a image that can zoom and pan/tilt. You can also use it inside any view just not ones that scroll.
var imageView = Titanium.UI.createImageView({ image:'loading.png', width:'auto', height:'auto', canScale:true });
-
I don't know the best way to handle image scaling on ipod or ipad. However, on android if you toss out the scrollview and use imageView alone with the "canScale" option set to true. You get a image that can zoom and pan/tilt. You can also use it inside any view just not ones that scroll.
var imageView = Titanium.UI.createImageView({ image:'loading.png', width:'auto', height:'auto', canScale:true });
-
I know it's been over a year, but is there any solution to this? I am stuck with the same problem.
-
You will never have an answer. I have same problem, it's just Titanium's bug, I don't believe they going to fix this