[TIMOB-19140] Ti.UI.ListView.dividerHeight does not accept value of 0
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | Medium |
Status | Closed |
Resolution | Fixed |
Resolution Date | 2015-07-03T02:27:26.000+0000 |
Affected Version/s | Release 4.1.0 |
Fix Version/s | Release 4.1.0 |
Components | Android |
Labels | listview, qe-4.1.0 |
Reporter | Chris Bowley |
Assignee | Ashraf Abu |
Created | 2015-07-02T08:37:39.000+0000 |
Updated | 2015-07-14T17:06:53.000+0000 |
Description
Ti.UI.ListView.dividerHeight does not accept value of 0 which means you cannot remove the divider in Android ListView.
https://github.com/appcelerator/titanium_mobile/blob/f8d4137ddbff4d1eacc7224f0cba1b374f7dec54/android/modules/ui/src/java/ti/modules/titanium/ui/widget/listview/TiListView.java#L500
Submitted PR https://github.com/appcelerator/titanium_mobile/pull/6952
Test code:-
4_1_X Backport PR: https://github.com/appcelerator/titanium_mobile/pull/6953
Thanks for the PR [~CollinPrice]. PR merged and back ported.
Some say we should also set the divider itself to
@null
: http://stackoverflow.com/questions/1914477/how-to-remove-line-inbetween-two-listviews-in-androidHmmm. I think it is acceptable right now to set it as 0 and not null. Is there any reason it has to be set to null as well? I'm trying to find out if it impacts anything if it is set to 0 and not null. So far, it seems to be working as expected.
Verified the fix. Closing. Environment: Appc Studio : 4.1.0.201507071122 Ti SDK : 4.2.0.v20150714071826, 4.1.0.GA Ti CLI : 4.0.1 Alloy : 1.6.2 MAC Yosemite : 10.10.4 Appc NPM : 4.1.0 Appc CLI : 4.1.0 Node: v0.10.37 Nexus 5 - Android 5.1.1 Genymotion emulator - android 4.4.4