Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
我创建了一个带有自定义模板的嵌套列表(我已经制作了自定义函数getItemTextTpl)。问题是我无法更改嵌套列表项的高度(附图片)。Sencha Touch 2.0.0 没有这个问题。是否有可能更改项目高度?
getItemTextTpl
我已经自己解决了这个问题。他们在 Sencha Touch v2.1 中添加了新的列表属性。 这些属性之一是itemHeight. 它是用于项目高度的属性(更多信息在这里)。要在嵌套列表中使用此属性,您必须初始化嵌套列表的属性listConfig。像这样:
itemHeight
listConfig
listConfig: { itemHeight: 100 }
也许您还需要检查新列表的属性variableHeights(更多信息在这里)。
variableHeights