Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-16704] Android: when showing a listview with a custom template, child elements are displayed incorrectly

GitHub Issuen/a
TypeBug
PriorityHigh
StatusClosed
ResolutionDuplicate
Resolution Date2014-06-17T20:35:50.000+0000
Affected Version/sRelease 3.2.2
Fix Version/sn/a
ComponentsAndroid
Labelsalloy, android, listview, listviewitem, template
ReporterUriel Arvizu
AssigneeHieu Pham
Created2014-03-24T23:26:24.000+0000
Updated2017-03-22T22:09:42.000+0000

Description

In an Alloy Project, when rendering a ListView with ListItems using an external Custom template, sometimes the Views contained in the vertical layout will be rendered not in proper order. For example, if my template contains a view with a vertical layout and inside it there are two child views, view A and view B, sometimes the order of the two will change, displaying sometimes A first and then B, while other times B will be first and A will be second. The expected behaviour should be for view A to be displayed always first and then view B should be underneath view A. I'm supplying two images showing the expected behaviour and the unexpected behaviour, plus a test project, if the items aren't rendered as in the unexpected behaviour image close the app and try again, sometimes it happens the first time and others after 5 or 6 tries. If the vertical layout is removed then the views overlaps on each other but which view is shown on top changes. For example, sometimes view A will be on top view B, while other times view B will be on top of view A. The expected behaviour here should be first view declared on the xml should be the one on the bottom while the last view declared on the xml should be the one on the top. The unexpected behaviour happens at an inconsistent rate so it's hard to predict when will it happen or at least I haven't being able to pinpoint what triggers the bug.

Attachments

FileDateSize
expected behaviour.png2014-03-24T23:43:47.000+0000162363
ListViewTemplateTest.zip2014-03-24T23:43:47.000+00006041784
unexpected behaviour.png2014-03-24T23:43:47.000+0000163733

Comments

  1. Ritu Agrawal 2014-03-26

    Moving this ticket to engineering as I can reproduce this issue with the attached test case.
  2. Uriel Arvizu 2014-04-02

    I just want to inform that this ticket hasn't even received a priority level. Can I get some feedback please?
  3. Uriel Arvizu 2014-06-02

    Just to confirm, this is still happening in 3.2.3.GA.
  4. Hieu Pham 2014-06-17

  5. Lee Morris 2017-03-22

    Closing ticket as duplicate and links to the related ticket have been provided above.

JSON Source