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

Adobe AIR Development

Reply
Super Contributor
JeffLemon
Posts: 438
Registered: ‎01-13-2011
My Carrier: NA

Multitouch?

Hi,

 

I want the user to be able to press two or more buttons in my app at the same time to trigger events, is there any special event listeners for this or will onMouseDown handle it just fine?

 

Thanks

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Please use plain text.
Developer
billfoust
Posts: 382
Registered: ‎05-19-2008
My Carrier: AT&T

Re: Multitouch?

Multi-touch isn't supposed in the simulator at this time. That might change how you want to implement things in your app (i.e. with only single touch instead). If I recall correctly, you need to listen for TOUCH events instead of MOUSE events if you do want to pursue implementing it. I was thinking there was another step that was needed as well - meaning that TOUCH events don't happen without doing something else first.

 

Hopefully that helps, a little anyway.

Bill

 

Bill
-------------------------------------------
Check out my book on BlackBerry Development for Java.
And my other really really old book
My Apps: FlashKids
Please use plain text.
Super Contributor
JeffLemon
Posts: 438
Registered: ‎01-13-2011
My Carrier: NA

Re: Multitouch?

Does anyone have a link with info on how to implement touch events?

 

Thanks

--------------------------------------------------------------------------------------------------
BlackBerry Apps: Instruments | ARTPAD | Piano | Drums | Xylophone
Please use plain text.
Developer
JRab
Posts: 2,462
Registered: ‎11-04-2010

Re: Multitouch?

theres a section in the developer guide for the playbook that can help you out a little:

 

http://docs.blackberry.com/en/developers/deliverables/23959/Responding_to_events_1425036_11.jsp

 

but keep in mind there is no way to test for this until the sim is update or the device comes out (whichever comes first). good luck!

J. Rab (Blog) (Twitter)
--
1. If you liked my post or found it useful please click on the thumbs up and provide a Like!
2. If my post solved your problem please click on the Accept as Solution button. Much appreciated!

Approved Apps: OnTrack | ssShots | Hangman
Please use plain text.
Developer
tensioncore
Posts: 323
Registered: ‎12-13-2010
My Carrier: Rogers

Re: Multitouch?

So, I have a question:

If all my event listeners (of which listen for "click" events) listen for MOUSEDOWN events, will this translate exactly the same as a TOUCH event?? because I mean....the whole interface is touch, but is there a difference? or is it just named that for the sake of not confusing...since we all develop using the Simulator/physical mouse.

CEO/Lead Developer - Tensioncore™ Design Studios
http://tncr.ws/ - ShortenThis!™ for Blackberry Playbook | ShortenThis!™ for BlackBerry® 10
The Periodical Toe A highly informative Table of Elements
DrawThis! A fun drawing app for the BlackBerry® PlayBook™!
http://www.tensioncore.com/ - Tensioncore™ Web Hosting
Please use plain text.
Developer
JRab
Posts: 2,462
Registered: ‎11-04-2010

Re: Multitouch?

hey nick,

 

from what i've read, the mouse inputs will be taken in as single touch points. unless your application is specifically listening for touch events, it will take ur mouse inputs as on finger tap kind of events. also i've read if your app only requires on touch point at any given time, then you should stick to mouse listeners because of the reduced overhead.

J. Rab (Blog) (Twitter)
--
1. If you liked my post or found it useful please click on the thumbs up and provide a Like!
2. If my post solved your problem please click on the Accept as Solution button. Much appreciated!

Approved Apps: OnTrack | ssShots | Hangman
Please use plain text.
Developer
UberschallSamsara
Posts: 839
Registered: ‎12-29-2010

Re: Multitouch?

There do exist AIR API's for multitouch - just google for "AIR multitouch API" & dig in.

 

Am guessing we'll get access to these on PlayBook on first release devices - mimicking them in the simulator takes some design on RIM's part (which I'd guess they are working on).  Other platforms' emulators use e.g. some key combinations w/the mouse click to emulate e.g. 2 finger pinch to zoom.

 

For example, http://developer.palm.com/index.php?option=com_content&view=article&id=1980&Itemid=337#MultipleTouch...

 

"You can emulate two-finger, multiple-touch events in your desktop app by holding down the CTRL key and moving your mouse within the app's window. The second touch event is mirrored across the X/Y axis from the mouse location."

Please use plain text.