Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-26086] Windows: Wrong event source after scaling with 2DMatrix

GitHub Issuen/a
TypeBug
PriorityMedium
StatusClosed
ResolutionFixed
Resolution Date2018-06-18T18:26:36.000+0000
Affected Version/sRelease 7.1.1
Fix Version/sRelease 7.3.0
ComponentsWindows
Labelsn/a
ReporterKota Iguchi
AssigneeKota Iguchi
Created2018-06-04T06:59:16.000+0000
Updated2018-06-20T15:49:01.000+0000

Description

Wrong source.id is returned after scaling the view with 2DMatrix.
var win = Ti.UI.createWindow({
    backgroundColor: 'green',
    width: 800,
    height: 400
});

var view = Ti.UI.createView({
    backgroundColor: 'red',
    width: '80%',
    height: '80%',
    id: 'view'
}), matrix = Ti.UI.create2DMatrix({
    scale: 0.5, anchorPoint: {x:0, y:0}
}),
    view2 = Ti.UI.createView({
        width: '70%', height: '70%', backgroundColor: 'blue', id: 'view2'
    });

view.add(view2);

view.addEventListener('click', function (e) {
    alert(e.source.id);
});

var animation = Ti.UI.createAnimation({
    transform: matrix,
    duration: 3000
});

win.addEventListener('open', function () {
    view.animate(animation);
});

win.add(view);
win.open();
Expected: When clicking on the blue view, it should prompt "view2".

Comments

  1. Kota Iguchi 2018-06-11

    https://github.com/appcelerator/titanium_mobile_windows/pull/1249
  2. Josh Longton 2018-06-18

    *FR* passed
  3. Gary Mathews 2018-06-18

    7_3_X: https://github.com/appcelerator/titanium_mobile_windows/pull/1259
  4. Josh Longton 2018-06-20

    *Closing ticket.* More information on steps and env can be found on the FR The fix is present in SDK: {noformat} 7.3.0.v20180618182516 {noformat}

JSON Source