[ALOY-833] Allow <Widget> as child of TableView

GitHub Issuen/a
Resolution Date2014-08-05T23:36:18.000+0000
Affected Version/sn/a
Fix Version/sAlloy 1.3.0, 2013 Sprint 23
ReporterTiman Rebel
AssigneeTony Lukasavage


When trying to build the following code:
    <Widget src="sc.SharingSettings" id="sharing" />
I get the following error: {color:red} [ERROR] : Child element must be one of the following: [Ti.UI.TableView.HeaderView,Ti.UI.TableView.HeaderPullView,Ti.UI.TableView.FooterView,Ti.UI.TableView.Search,Ti.UI.TableViewRow,Ti.UI.TableViewSection,Ti.UI.SearchBar] {color} Could you please add Widget as valid child of TableView? I am allowed to put a Widget inside a TableViewSection


  1. Tony Lukasavage 2013-09-23 [~timanrebel] what is in your widget?
  2. Timan Rebel 2013-09-23 sc.SharingSettings:
           <Widget src="sc.GroupedTable" id="groupedTable" />
    sc.GroupedTable's widget controller creates a set of Ti.UI.TableViewSection, which it adds via $.addTopLevelViews. The GroupedTable widget used to have its own TableView, but I wanted more flexibility. Like adding 2 widgets into 1 tableview.
  3. Tony Lukasavage 2013-09-23 I think I can facilitate this by allowing empty widgets to be part of the hierarchy.
  4. Timan Rebel 2013-09-23 I noticed that adding a TableViewSection to sc.GroupedTable didn't seem to work. Maybe because the hierarchy is then: TableView -> Widget -> Widget -> TableViewSection
  5. Tony Lukasavage 2013-09-23 [~timanrebel] can you turn this into a reproducible test case? I've got some of the bits and pieces here, but I'm obviously missing some elements necessary to actually run this on my end.
  6. Tony Lukasavage 2013-11-04 This issue was resolved by an earlier commit. The PR below represents a test app created to confirm the fix. PR: https://github.com/appcelerator/alloy/pull/268 Functional test should be simply running the app, confirming that there are no compile time or runtime errors, and asserting that the table section in the app's widget is shown (5 simple rows).
  7. Federico Casali 2013-12-03 Verified fixed. TiSDK 3.2.0.v20131127194046 CLI 3.2.0-beta Alloy 1.3.0-beta Titanium Studio iPad OS 7 and simulator Android Google Nexus Galaxy 4.3 MobileWeb (for sample #2) Closing.

JSON Source