Problem description
When using windowSoftInputMode, the dimensions returned in the postlayout event are not correct.
Steps to reproduce
Use the following code to reproduce the issue. Removing windowSoftInputMode will return the right height for the window.
Titanium.UI.setBackgroundColor('#000');
var win1 = Titanium.UI.createWindow({
title:'Tab 1',
backgroundColor:'#fff',
windowSoftInputMode: Ti.UI.Android.SOFT_INPUT_ADJUST_PAN
});
win1.addEventListener('postlayout', function(e) {
Ti.API.info('rect.height: '+e.source.rect.height);
alert('rect.height: '+e.source.rect.height);
});
win1.open();
Notes
Works with 3.0.2
https://github.com/appcelerator/titanium_mobile/pull/4358
3.1.X PR : https://github.com/appcelerator/titanium_mobile/pull/4359
Verified as fixed with TiSDK 3.1.1.v20130606121419 on Android Galaxy Nexus 4.2.2 Closing.