[TIMOB-16772] Android: Drag animation not working
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Low |
Status | Closed |
Resolution | Duplicate |
Resolution Date | 2014-03-28T21:13:01.000+0000 |
Affected Version/s | Release 3.2.3 |
Fix Version/s | n/a |
Components | Android |
Labels | qe-3.2.3, triage |
Reporter | Priya Agarwal |
Assignee | Hieu Pham |
Created | 2014-03-28T11:27:51.000+0000 |
Updated | 2017-03-20T22:42:16.000+0000 |
Description
Not a regression since issue occurs in 3.2.2.GA and 3.2.1.GA also
Steps to reproduce:
1. Copy paste the below given code in app.js and run the app on android device.
2. Drag Square on screen
Expected Result:
Drag animation should work fine.
Actual Result:
No drag animation observed.
Drag Animation working fine on ios.
var win = Ti.UI.createWindow({
backgroundColor : "#fff"
});
var annoViewPosition;
var view = Ti.UI.createView({
borderWidth : 1,
borderColor : "#000000",
left : 0,
top : 0,
height: 100,
width: 100
});
win.add(view);
var lbltop;
var lblleft;
view.addEventListener('touchstart', function(e) {
annoLblPosition = {
top : e.source.top,
left : e.source.left
};
lbltop = e.y;
lblleft = e.x;
});
view.addEventListener('touchmove', function(e) {
annoLblPosition.top += e.y - lbltop;
annoLblPosition.left += e.x - lblleft;
e.source.animate({
top : annoLblPosition.top,
left : annoLblPosition.left,
duration : 5,
});
});
win.open();
Closing ticket as duplicate.