Titanium JIRA Archive
Appcelerator Community (AC)

[AC-1521] ListView.footerView / setFooterView(view) is not working on Android

GitHub Issuen/a
TypeBug
Priorityn/a
StatusClosed
ResolutionInvalid
Resolution Date2015-04-21T18:38:44.000+0000
Affected Version/sn/a
Fix Version/sn/a
ComponentsTitanium SDK & CLI
LabelsTCSupportTriage, andorid, footerview, listview
ReporterManojkumar Murugesan
AssigneeHieu Pham
Created2014-10-21T10:18:56.000+0000
Updated2016-03-08T07:37:58.000+0000

Description

Android - Unable to set footerView of ListView once it is rendered. Has no effect when use,
$.listView.footerView = footerView;
and when setFooterView is called, the following error is printed on the console.
[ERROR] :  TiExceptionHandler: (main) [6821,8711] ----- Titanium Javascript Runtime Error -----
[ERROR] :  TiExceptionHandler: (main) [0,8711] - In undefined:35,20
[ERROR] :  TiExceptionHandler: (main) [1,8712] - Message: Uncaught TypeError: Object #<ListView> has no method 'setFooterView'
[ERROR] :  TiExceptionHandler: (main) [0,8712] - Source:         $.listView.setFooterView(null);
[ERROR] :  V8Exception: Exception occurred at undefined:35: Uncaught TypeError: Object #<ListView> has no method 'setFooterView'
Additional notes : Works as expected on iOS. On Android - able to set footerView only on creation.

Comments

  1. Hieu Pham 2015-04-21

    On Android, headerView and footerView are creation only properties (http://docs.appcelerator.com/platform/latest/#!/api/Titanium.UI.ListView-property-headerView). This is because it is required that we have to add header and footer views before setting the adapter.
  2. Manojkumar Murugesan 2015-04-21

    Hi [~hpham], This is not documented in list view. It must be documented.
  3. Hieu Pham 2015-04-21

    Manoj, this is documented: http://docs.appcelerator.com/platform/latest/#!/api/Titanium.UI.ListView-property-headerView
  4. Manojkumar Murugesan 2015-04-21

    Sorry, It is documented. My bad :(

JSON Source