Titanium JIRA Archive
Titanium SDK/CLI (TIMOB)

[TIMOB-18134] Layout not working while set touch enable=false inside Listview

GitHub Issuen/a
TypeBug
Priorityn/a
StatusOpen
ResolutionUnresolved
Affected Version/sn/a
Fix Version/sn/a
ComponentsTiAPI
LabelsLayout, ListView, touchEnabled
ReporterKrishnadas
AssigneeUnknown
Created2014-12-03T05:34:26.000+0000
Updated2018-02-28T19:55:10.000+0000

Description

When I set touchEnabled="false" for a view which was inside my List view template all my list view layout was broken. when i remove the touch enabled property it working fine Here is sample code
<Alloy>
	<Window backgroundColor="#fff">
		<ListView id="LstView" top="50" defaultItemTemplate="template1">
			<Templates >
				<ItemTemplate id="mytemplate" name="template1">
					<View layout="horizontal" width="Ti.UI.FILL" touchEnabled="false">
						<View width="Ti.UI.SIZE" height="Ti.UI.SIZE" left="5">
							<Label bindId="Lbl1" Id="Lbl1" color="black"></Label>
						</View>
						<View width="Ti.UI.SIZE" height="Ti.UI.SIZE" left="10" >
							<Label bindId="Lbl2" Id="Lbl2" color="black"></Label>
						</View>
						<View width="Ti.UI.SIZE" height="Ti.UI.SIZE" left="10">
							<Label bindId="Lbl3" Id="Lbl3" color="black" ></Label>
						</View>
					</View>
				</ItemTemplate>
			</Templates>
			<ListSection>
				<ListItem Lbl1:text="hello" Lbl2:text="how are you?" Lbl3:text="I am fine" height='70'/>
			</ListSection>
		</ListView>
	</Window>
</Alloy>
$.index.open();

Attachments

FileDateSize
Not set touchEnable property.png2014-12-03T11:53:55.000+000022899
touchEnable set false.png2014-12-03T11:55:23.000+000022417

Comments

  1. Shuo Liang 2014-12-03

    Hi Please provide screen shots for your test between set touch enable=false and not. Also based on your code, we can't tell the difference between whether or not there set touch enable=false. So Please provide a more obvious simple test case to reproduce your problem. Thanks Regards, Shuo
  2. Krishnadas 2014-12-03

    Above 2 attachments shows while i run the same code with and without touchEnable property. Both have different alignment in IOS8 stimulator. Horizontal alignment property not working while we set touchEnable=false. Use the same sample Code.
  3. Shuo Liang 2014-12-04

    Hi, I can see the problem. It seems a little bug here. Will forward ticket to our engineer team. Thank you for your report. Regards, Shuo
  4. Krishnadas 2014-12-04

    Thanks for your support.

JSON Source