开发者

sencha framework problem after update 2.2 to 3.3.1

开发者 https://www.devze.com 2023-02-13 09:13 出处:网络
After ExtJS update 2.2 to 3.3.1 i have got a problem i can\'t solve. I think its a TreePanel that is created. But there is no childNodes in \"this\"-object so:

After ExtJS update 2.2 to 3.3.1 i have got a problem i can't solve.

I think its a TreePanel that is created. But there is no childNodes in "this"-object so:

ERROR: cs is null

renderChildren : function(suppressEvent){
    if(suppressEvent !== false){
   开发者_如何学Go     this.fireEvent('beforechildrenrendered', this);
    }
    var cs = this.childNodes;
    for(var i = 0, len = cs.length; i < len; i++){
        cs[i].render(true);
    }
    this.childrenRendered = true;
}, 

I can't figure out what is causing this problem, can't find who is calling this command.


this is probably window. Check that context (this) is set properly when the function is called (or event attached).


Found it in by looking in stack:

MapPanel.js (rad 77)

Code:

        var toc = new MyPanel.Toc( {
            map :map,
            border :false
        });
        tocPanel.add(toc);
        //toc.update(); //When i comment out these it works. 
        //tocPanel.doLayout();

"A TreePanel must have a root node before it is rendered." class=Ext.tree.TreePanel

Could it be this?

0

精彩评论

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

关注公众号