[AC-869] Android borderRadius property not working with using view layout = "horizontal"
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Closed |
Resolution | Cannot Reproduce |
Resolution Date | 2014-09-19T07:32:41.000+0000 |
Affected Version/s | n/a |
Fix Version/s | n/a |
Components | n/a |
Labels | TCSupportTriage, android, borderRadius, listView |
Reporter | Kerberos |
Assignee | Mauro Parra-Miranda |
Created | 2014-08-29T08:59:17.000+0000 |
Updated | 2016-03-08T07:37:10.000+0000 |
Description
My codes as below. When i debug my codes on iOS everything is OK. Child ıtems shows left to right.
But on Android, child items not looking right. I have worked hard to find issue source.
Finally when I modify borderRadius property to 0 (zero) everything is OK like iOS.
var $ListViewLinksTemplate = {
childTemplates : [{
type : 'Ti.UI.View',
properties : {
top : 9,
width : Ti.UI.SIZE,
height : Ti.UI.SIZE,
backgroundColor : "transparent",
layout : "horizontal",
},
childTemplates : [{
type : 'Ti.UI.View',
properties : {
top : 0,
left : 0,
width : 30,
height : 30,
backgroundColor : Alloy.Globals.Color2,
borderRadius: 6
},
childTemplates : [{
type : 'Ti.UI.ImageView',
bindId : '_ImageViewIcon',
properties : {
width : 26,
height : 26,
}
}]
}, {
type : 'Ti.UI.View',
bindId : '_ViewForLabels',
properties : {
layout : "vertical",
left : 5,
width : 100,
height : Ti.UI.SIZE
},
childTemplates : [{
type : 'Ti.UI.Label',
bindId : '_LabelHeader',
properties : {
width : "100%",
height : Ti.UI.SIZE,
textAlign : Ti.UI.TEXT_ALIGNMENT_LEFT,
color : Alloy.Globals.Color5,
text : "",
font : {
fontSize : 16,
fontFamily : Alloy.Globals.CustomFont
}
}
}, {
type : 'Ti.UI.Label',
bindId : '_LabelExplain',
properties : {
bottom : 3,
width : "100%",
height : Ti.UI.SIZE,
textAlign : Ti.UI.TEXT_ALIGNMENT_LEFT,
color : Alloy.Globals.Color10,
text : "",
font : {
fontSize : 12,
fontFamily : Alloy.Globals.CustomFont
}
}
}],
}, {
type : 'Ti.UI.ImageView',
properties : {
image : "images/icon-right-arrow.png",
width : 16,
height : 16
}
}],
}],
properties : {
accessoryType : Ti.UI.LIST_ACCESSORY_TYPE_NONE,
height : Ti.UI.SIZE,
backgroundColor : "transparent",
selectedBackgroundColor : "transparent",
selectionStyle : Alloy.Globals.PlatformName == 'iPhone OS' ? Ti.UI.iPhone.ListViewCellSelectionStyle.NONE : "transparent",
}
};
Attachments
File | Date | Size |
---|---|---|
Snap3.png | 2014-08-29T08:59:17.000+0000 | 144664 |
Hello, We have tested this issue with our sample code. Its not a bug. It works as we expect. If *borderRadius* is specified as an integer then we need to set
in the TiApp.xml *TESTING ENVIRONMENT:* Titanium SDK: 3.3.0.GA and 3.2.3.GA Titanium CLI: 3.3.0 OS X Version: 10.9.3 Android API Level: 17 and 19 *STEPS TO REPRODUCE:* a) Create a simple project. b) Update this code in app.js c) Run this with testing environment *TESTING CODE:*
*In Alloy Project* index.xml
index.js
*TESTING RESULT:* Its working perfectly.