开发者

infinite(till the end) display buffered contents, in a sencha touch mobile app

开发者 https://www.devze.com 2023-04-02 19:15 出处:网络
I had a fairly long list to display in my sencha touch mobile app, due to the contents of the list, the app was pretty heavy and then i found this great toolit increased the efficiency drastically But

I had a fairly long list to display in my sencha touch mobile app, due to the contents of the list, the app was pretty heavy and then i found this great tool it increased the efficiency drastically But the issue which comes with this library is that it would display the first 70 items, and when you scroll down it does not display things at all. Has anyone dealt with it. Please let me know.

Mentioned below is the sample of the test-code, which will help you simulate.

Ext.reg('mylist', Ext.ux.BufferedList);

var data = [];
for (var i = 0; i < 600000; i++)
    data.push({
        firstName: 'Mark' + i,
        lastName: 'Taylor'
    });

Ext.setup({
    onReady: function() {
        Ext.regModel('Contact', {
            fields: ['firstName', 'lastName']
        });

        var store = new Ext.data.Store({
            model: 'Contact',
            data: data
        });

        new Ext.TabPanel({
            layout: 'f开发者_如何学Cit',
            fullscreen: true,
            scroll: 'vertical',
            items: [{
                title: 'MyPanel',
                xtype: 'panel'},
            {
                title: 'MyList',
                fullscreen: true,
                xtype: 'mylist',
                itemTpl: '{firstName} {lastName}',
                store: store}]
        });
    }
});


https://gist.github.com/1244583 this is what you are searching i guess!!

the only updation i have made is in line 35!!

0

精彩评论

暂无评论...
验证码 换一张
取 消