[TIMOB-2501] Android: UI.KEYBOARD_NUMBERS_PUNCTUATION constant causes return to be suppressed
| GitHub Issue | n/a | 
|---|---|
| Type | Bug | 
| Priority | Low | 
| Status | Closed | 
| Resolution | Invalid | 
| Resolution Date | 2017-06-07T22:46:20.000+0000 | 
| Affected Version/s | Release 3.0.0 | 
| Fix Version/s | n/a | 
| Components | Android | 
| Labels | api | 
| Reporter | Paul Dowsett | 
| Assignee | Ingo Muschenetz | 
| Created | 2011-04-15T03:21:24.000+0000 | 
| Updated | 2017-06-07T22:46:20.000+0000 | 
Description
Tested on android 1.4.X and 1.5.X, the following code demonstrates that return is suppressed if keyboardType:Ti.UI.KEYBOARD_NUMBERS_PUNCTUATION is set. If you comment out this line, the correct, default behaviour (where a new line is inserted when return is pressed) is observed.
var win = Ti.UI.createWindow({  
    backgroundColor:'white',
    navBarHidden:false,
    title:'This is window 1'
});
var ta1 = Titanium.UI.createTextArea({
    value:'I am a textarea',
    height:70,
    width:300,
    keyboardType:Titanium.UI.KEYBOARD_NUMBERS_PUNCTUATION,  // problem
    top:10
});
win.add(ta1);
var l = Titanium.UI.createLabel({
    text:'Text area tests.',
    font:{fontSize:14},
    left:10,
    top:100,
    width:300,
    height:'auto'
});
win.add(l);
ta1.addEventListener('change',function(e)
{
    l.text = 'change fired, value = ' + e.value;
});
win.open();
Note that other constants don't seem to cause the same issue, for example keyboardType:Ti.UI.KEYBOARD_ASCII, although I haven't tested them all.
Tested on a Samsung Galaxy S2 using TiSDK 2.2.0v20120821095711, issue still valid.
Closing ticket due to the time passed and lack of progress.