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
Super Contributor
Posts: 440
Registered: ‎01-13-2011
My Device: Playbook
My Carrier: NA

Touch Out

I have an image view that changes when it is touched and it changes back to it's original state when the user stops touching it.

 

The problem is, sometimes the device does not register a touch up on the image, perhaps becuase the user touches the image and drags his/her finger out of the image view. So a touch up is never captured.

 

Is there a way to do a touch out? So I can turn teh image view back to its original state if the user is no longer touching it.

 

I'm using C++.

 

Thnaks!

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Super Contributor
Posts: 440
Registered: ‎01-13-2011
My Device: Playbook
My Carrier: NA

Re: Touch Out

*bump*

 

Is there no way to do a touch out, seems a little bit of an oversight?

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Contributor
Posts: 45
Registered: ‎04-11-2012
My Device: Z10 Limited Edition
My Carrier: 00201003883386

Re: Touch Out

[ Edited ]

Put a touch event (Mouse Move) on the container of the image view. this will handle your missing case.

 

if this event is fired, it means that users moved his finger outside the image view and moved inside the container. 

 

 

When you are young, work to learn. Not to earn !
Highlighted
Developer
Posts: 96
Registered: ‎10-06-2012
My Device: Z10
My Carrier: Rogers

Re: Touch Out

I haven't tried this in C++ but in QML you can use onTouchEnter and onTouchExit...so in your case, onTouchExit will fire whenever the user's finger exists the image.

Hope that helps.
Jason I. Carter
Follow me @jasonicarter
Built For BlackBerry - WordsPlus & WordsPlus: Free Edition | word search has never had it so good
www.twocasualcoders.com | never casual on quality