[TIMOB-12537] BlackBerry: Define Ti.UI.SIZE and Ti.UI.FILL constants
GitHub Issue | n/a |
---|---|
Type | New Feature |
Priority | High |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2013-02-02T07:53:49.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Release 3.1.0, 2013 Sprint 03 BB, 2013 Sprint 03 |
Components | BlackBerry |
Labels | n/a |
Reporter | Russell McMahon |
Assignee | Josh Roesslein |
Created | 2013-01-31T22:56:04.000+0000 |
Updated | 2017-03-09T01:00:25.000+0000 |
Description
The SIZE and FILL constants need to be defined on the UI module.
The layout engine expects the current values:
- SIZE -> "UI.SIZE"
- FILL -> "UI.FILL"
Acceptance Test
Ti.API.info('Ti.UI.FILL = ' + Ti.UI.FILL);
Ti.API.info('Ti.UI.SIZE = ' + Ti.UI.SIZE);
var win = Ti.UI.createWindow();
var view = Ti.UI.createView({
backgroundColor: 'blue',
width: Ti.UI.FILL, height: Ti.UI.SIZE
});
win.add(view);
var childView = Ti.UI.createView({
backgroundColor: 'red',
width: 200, height: 200
});
view.add(childView);
win.open();
1. The FILL and SIZE constant values should be printed to the log.
Verify they contain the correct value ('UI.SIZE', 'UI.FILL').
2. A blue view should be visible that fills the window horizontally
and sizes vertically to fit it's child view (red).
3. A red view should be visibile that fills vertically and is 200 dp horizontally.
Created pull request [#22](https://github.com/appcelerator/titanium_mobile_blackberry/pull/22) to resolve issue.
Closing ticket as fixed.