Hello all,
I use a list with infinite arg in sencha touch, and trying to scroll to the end, but the record become at the bottom of list. When I pull down the list, the record become to the top. Is there any solution for fixed the record to the top of list whatever scrollToTop or scrollToEnd. Thanks.
record stick at the bottom when scrolling infinite list to the end
I use a list with infinite arg in sencha touch, and trying to scroll to the end, but the record become at the bottom of list. When I pull down the list, the record become to the top. Is there any solution for fixed the record to the top of list whatever scrollToTop or scrollToEnd. Thanks.
The following is my code.
Code:
Ext.define('infiniteList.view.Main', {
extend: 'Ext.Container',
xtype: 'main',
config: {
layout: 'vbox',
items: [
{
xtype: 'list',
id: 'infiniteList',
flex: 1,
data: [{
objectId: 'a',
name: 'Tester',
text: 'test'
}],
infinite: true,
itemTpl: new Ext.XTemplate(
'<div>{name}: {text}</div>'
)
}
]
}
});
scroll command:
Code:
Ext.getCmp('infiniteList').getScrollable().getScroller().scrollToEnd()
record stick at the bottom when scrolling infinite list to the end
Aucun commentaire:
Enregistrer un commentaire