[TIMOB-8616] iOS: Swipe event's direction returns 'unknown' when it was 'left' or 'right'
| GitHub Issue | n/a |
| Type | Bug |
| Priority | High |
| Status | Closed |
| Resolution | Fixed |
| Resolution Date | 2012-07-10T02:16:03.000+0000 |
| Affected Version/s | Release 1.8.3 |
| Fix Version/s | Release 2.0.2, Release 2.1.0, Sprint 2012-08, Release 1.8.3 |
| Components | iOS |
| Labels | api, module_view, qe-testadded |
| Reporter | Varun Joshi |
| Assignee | Vishal Duggal |
| Created | 2012-04-09T12:33:07.000+0000 |
| Updated | 2012-07-10T15:43:55.000+0000 |
Description
Problem
The swipe event listener is returning a direction with a value of 'unknown' instead of the 'left' or 'right'. This is with build: Apr 5 2012 15:35 rd56dc6a6 of the 1.8.3 SDK.
The last build of the 1.8.3 that worked was Apr 2 2012 16:18 rb763622c.
Steps to Reproduce
1. Run the code sample below:
{noformat}
var win = Ti.UI.createWindow({
top: 0,
right: 0,
bottom: 0,
left: 0,
});
var view = Ti.UI.createView({
top: 100,
left: 100,
width: 200,
height: 200,
backgroundColor: 'red'
});
view.addEventListener('swipe', function(evt) {
Ti.API.log('direction: ' + evt.direction);
});
win.add(view);
win.open();
{noformat}
2. Click in red view and swipe. On simulator, 'unknown' is printed out to the console.
Comments
JSON Source
Pull pending against master https://github.com/appcelerator/titanium_mobile/pull/1965.
Tested with 2.0.2.v20120505151714 on iPad 2 5.1
Reopening to update labels.