Welcome!

Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Native Development

Reply
Regular Contributor
Posts: 83
Registered: ‎07-19-2012
My Device: Bold 9790, Dev Alpha A
My Carrier: Koodo

Touch interaction with more than one object/control

After creating some code that moves, rotates and re-sizes controls (i.e. imageView, label) (found here) I began to notice that objects don't interact very well together when both are touched at the same time.

 

Is there a way to disable touch interaction of an object or control if another control has already been touched?

Retired
Posts: 155
Registered: ‎07-16-2012
My Device: Dev Alpha
My Carrier: Bell

Re: Touch interaction with more than one object/control

Hi CrozyBB,

 

please have a look at this, hope it helps. https://developer.blackberry.com/cascades/reference/bb__cascades__touchpropagationmode.html

 

 

Highlighted
Regular Contributor
Posts: 83
Registered: ‎07-19-2012
My Device: Bold 9790, Dev Alpha A
My Carrier: Koodo

Re: Touch interaction with more than one object/control

Thanks amarcon, I looked through that a couple days ago and thought I was on the right track by setting the touch propagation mode to PassThrough for each element (i.e. imageView in my case) that was not being touch by the user.

 

However, I ran into a problem where if an element that was not being touched and was also layered above the element that was being touched it would not flow underneath it. This also essentially stopped the touch interaction with the element that was being touched.

 

With that said I was hoping there would be some way that I could bring an element that was touched by the user to the top and overlay all the other elements. To get an idea of what I would like to accomplish here you can take a look at the Scrapbook app for PlayBook -> even if an image is overlayed by other images, once it is touched by the user it then overlays all other images.

 

I started another thread on this specific issue (here) so we can close down this thread to make things easier