View Full Version : Touch Gestures

20 Oct 2012, 5:28 PM

I want to create very simple interactive iPhone mockups (mostly screen transitions and animating elements) using Sencha Animator for our developers. Is it possible to use touch gestures, I know there are libraries such as hammer.js that does exactly what I need but how to implement this in Sencha Animator I'm not sure. An example project would be great.


23 Oct 2012, 1:42 PM
Sorry, we don't have any example projects in this area yet. I think your best bet might be to include your library using the Includes->External JS option in the Project tab. Then I would initialize and set up your library it in the Actions->Start (also in the project tab).

If you are using Hammer.js, something like this might work out for you as the start action (this assumes you have an element in a scene, with a ID of "box" (given under Properties->General->ID) for any object.

var hammerBox = new Hammer(controller.getElementById('box'));
hammerBox.onswipe = function (event) {