[TIMOB-24637] Windows Hyperloop: accessing generic collections throws exception
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2017-05-04T23:03:16.000+0000 |
Affected Version/s | Hyperloop 2.1.0 |
Fix Version/s | Hyperloop 2.1.1 |
Components | Windows |
Labels | hyperloop-windows |
Reporter | Kota Iguchi |
Assignee | Kota Iguchi |
Created | 2017-04-27T02:09:08.000+0000 |
Updated | 2017-05-17T13:23:10.000+0000 |
Description
Accessing properties/functions on generic collections on Hyperloop throws exception.
var MessageDialog = require('Windows.UI.Popups.MessageDialog'),
UICommand = require('Windows.UI.Popups.UICommand'),
PropertyValue = require('Windows.Foundation.PropertyValue'),
Int32 = require('System.Int32');
var dialog = new MessageDialog('My Message');
dialog.Title = 'My Title';
dialog.DefaultCommandIndex = 0;
dialog.Commands.Add(new UICommand('OK', null, PropertyValue.CreateInt32(0)));
dialog.Commands.Add(new UICommand('Cancel', null, PropertyValue.CreateInt32(1)));
dialog.ShowAsync().then(function (command) {
var id = Int32.cast(command.Id);
alert((id == 0) ? 'Pushed "OK"' : 'Pushed "Cancel"')
});
*Expected:*
* This should show alert dialog with two buttons: \[OK\] \[Cancel\] when you click "Show Alert"
* When you click \[OK\] you should see "Pushed "OK"
* When you click \[Cancel\] you should see "Pushed "Cancel"
https://github.com/appcelerator/hyperloop.next/pull/165
Verified using: Windows 10 Pro Ti SDK: 6.1.0.v20170516173434 Appc CLI: 6.2.2-master.13 Appc NPM: 4.2.9 Hyperloop: 2.1.1 (https://github.com/appcelerator/hyperloop.next/tree/2_1_X/windows/dist) Windows 10 Mobile emulator Lumia 550 (10.0) Windows Phone 8.1 emulator Lumia 520 (8.1) Able to call functions like IndexOf, Clear, Insert etc. with no issues and access properties like Count. Closing ticket