You found a bug! We've classified it as EXTJS-8289 . We encourage you to continue the discussion and to find an acceptable workaround while we work on a permanent fix.
  1. #1
    Sencha Premium Member
    Join Date
    Jan 2010
    Location
    Vancouver, Canada
    Posts
    137
    Vote Rating
    29
    bogc will become famous soon enough bogc will become famous soon enough

      0  

    Default Buffered rendered TreePanel setRootNode fails when the tree has been scrolled down

    Buffered rendered TreePanel setRootNode fails when the tree has been scrolled down


    Ext version tested:
    • Ext 4.2.0.265

    Browser versions tested against:
    • Chrome 24.0.1312.52 m
    • IE9

    Description:

    I have a TreePanel configured with the BufferedRenderer plugin. After the tree is loaded, and after I scroll down the tree a couple of pages (via PageDown), if I try to reload the tree it fails with:

    Unable to get value of the property 'insertSibling': object is null or undefined
    in this function:

    Code:
        doAdd: function(records, index) {
            var me = this,
                nodes = me.bufferRender(records, index, true),
                all = me.all,
                count = all.getCount(),
                i, l;
    
            if (count === 0) {
                for (i = 0, l = nodes.length; i < l; i++) {
                    this.getNodeContainer().appendChild(nodes[i]);
                }
            } else if (index < count) {
                if (index === 0) {
                    all.item(index).insertSibling(nodes, 'before', true);
                } else {
                    all.item(index - 1).insertSibling(nodes, 'after', true);
                }
            } else {
                all.last().insertSibling(nodes, 'after', true);
            }
    
            all.insert(index, nodes);
            return nodes;
        },
    at this line:

    Code:
    all.item(index).insertSibling(nodes, 'before', true);

    Steps to reproduce the problem:

    • Unzip the attached file in a directory where you can open app.html in your own web server of choice. Before you do that you might have to change app.html to point to the local directory where you keep extjs 4.2.0.265
    • Assuming you've successfuly opened the page in a browser, click on the Load Tree button. The data is loaded and alert message is displayed. Click the OK button.
    • Select the first node in the tree
    • Now press PageDown twice (now, this depends on how big the browser window is, you might have to scroll down more, basically enough to force the buffer to kick in)
    • Click again on the Load Tree button. This time the browser fails to reload the tree
    The result that was expected:
    • The second click should reload the tree
    The result that occurs instead:
    • The tree is not reloaded and the mask stays on. When debugging in IE9 and VS 2010 the page fails with the error described above
    Attached Files

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    37,548
    Vote Rating
    872
    mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute mitchellsimoens has a reputation beyond repute

      0  

    Default


    Thanks for the report! I have opened a bug in our bug tracker.

  3. #3
    Sencha User
    Join Date
    Sep 2011
    Posts
    6
    Vote Rating
    1
    pavleg is on a distinguished road

      1  

    Default Progress?

    Progress?


    Hi,

    Any progress on this bug? I am having similar issues with BufferedRenderer.

    Regards

  4. #4
    Sencha User
    Join Date
    May 2012
    Posts
    1
    Vote Rating
    0
    fgiannar is on a distinguished road

      0  

    Default


    Reporting the same bug as well. Is there maybe a workaround for this at the premium forums?

  5. #5
    Sencha User george.antoniadis's Avatar
    Join Date
    Jul 2007
    Posts
    107
    Vote Rating
    1
    george.antoniadis is on a distinguished road

      0  

    Default


    This seems to have been fixed at least in 4.2.1.883
    The provided sample is working if anyone affected could please provide some feedback it would be very helpful.

    Thanks.