Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-25794] Windows: Adding a hyperloop created UI element to a View crashes the app

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionFixed
Resolution Date2018-02-22T23:10:59.000+0000
Affected Version/sRelease 7.1.0, Release 7.2.0
Fix Version/sRelease 7.1.0
ComponentsHyperloop, Windows
Labelsregression
ReporterEwan Harris
AssigneeKota Iguchi
Created2018-02-21T18:15:36.000+0000
Updated2018-05-16T23:37:55.000+0000

Description

Description

*This is a regression from 7.0.2.GA* When adding a UI element that is created using hyperloop to a Ti.UI.View the app will crash with no logs
var win = Ti.UI.createWindow();
var Canvas = require('Windows.UI.Xaml.Controls.Canvas');
var SolidColorBrush = require('Windows.UI.Xaml.Media.SolidColorBrush');
var Colors = require('Windows.UI.Colors');
var view = Ti.UI.createView({
	backgroundColor: 'fuchsia'
});
var box = new Canvas();
box.Background = new SolidColorBrush(Colors.Red);
box.Width = 50;
box.Height = 50;
win.addEventListener('click', function() {
	view.add(box); 
});
win.add(view);
win.open();

Steps to reproduce

1. Add the above code to an existing classic project with hyperloop setup 2. Build for any Windows target 3. Click the view when the app launches

Actual

App crashes

Expected

App should not crash

Comments

  1. Ewan Harris 2018-02-21

    Note, this was found while running through the hyperloop-examples app, namely the View Animation example https://github.com/appcelerator/hyperloop-examples/blob/master/app/views/windows/animateview.xml
  2. Kota Iguchi 2018-02-22

    master: https://github.com/appcelerator/titanium_mobile_windows/pull/1200 7_1_0: https://github.com/appcelerator/titanium_mobile_windows/pull/1201
  3. Kota Iguchi 2018-02-22

    Merged.
  4. Ewan Harris 2018-03-05

    Verified changes in 7.2.0.v20180302144729 and 7.1.0.v20180302141418. Closing ticket

JSON Source