[ALOY-461] Alloy - Allow usage of "Require" or "Widget" in TableView
GitHub Issue | n/a |
---|---|
Type | Improvement |
Priority | Medium |
Status | Resolved |
Resolution | Fixed |
Resolution Date | 2013-03-19T03:13:16.000+0000 |
Affected Version/s | n/a |
Fix Version/s | Alloy 1.1.0, 2013 Sprint 06 |
Components | XML |
Labels | alloy |
Reporter | Jick Steen |
Assignee | Unknown |
Created | 2013-01-11T13:15:50.000+0000 |
Updated | 2018-03-07T22:26:04.000+0000 |
Description
See discussion:https://groups.google.com/forum/#!topic/appc-ti-alloy/wCIpVlJX8MQ
Hi all,
I think widgets for Rows/Sections are not really reusable across multiple applications at the moment. I have a feature wish to allow Require or Widget elements in TableView view markup.
Example:
<TableView>
<TableViewRow title="1"/>
<TableViewRow title="2"/>
<Require type="widget" src="org.test.tableviewsection" title="section" />
<Require type="widget" src="org.test.tableviewrow" title="row" />
<TableViewRow title="3"/>
</TableView>
widget.xml would contain a markup as follows:
<TableViewSection platform="android"><HeaderView><Label>Test</Label></HeaderView></TableViewSection>
<TableViewSection platform="ios,mobileweb" headerTitle="Test"/>
I know it could maybe work like this:
<TableViewSection><Require type="widget" src="org.test.tableviewsection" title="section" /></TableViewSection>
But not in the use case above.
Because of this limitation I have to create all of my tables in JS and cannot use any markup / styles. Alternatively I would have to copy/paste the widget.xml markup for each Section/Row.
Cheers
Resolved and 2 uses cases in the test app: https://github.com/appcelerator/alloy/tree/master/test/apps/advanced/tableview_requires
https://github.com/appcelerator/alloy/tree/master/test/apps/advanced/tableview_requires is not available. Please provide the same.