1. #1
    Ext JS Premium Member
    Join Date
    Mar 2010
    Posts
    21
    Vote Rating
    0
    Maarten76 is on a distinguished road

      0  

    Default TreePanel sometimes looks collapsed (height not set?)

    TreePanel sometimes looks collapsed (height not set?)


    Very occasionally, a TreePanel which is used in software I've built does not have the correct height.

    Screen Shot 2012-12-11 at 11.45.20 AM.png

    This only happens in Chrome and Windows XP. It doesn't happen all of the time. I used several machines with the same setup and only some of them have this problem.

    The code of the treepanel is this:

    Code:
    var ouTreePanel = new Ext.tree.TreePanel({        id: 'ou-tree-panel'
            ,layout: 'fit'
            ,frame: false
            ,border: false
            ,autoScroll: false
            ,rootVisible: false
            ,root: ouRoot
            ,loader: ouLoader
            ,listeners: {
                'click': selectOrganization
                
            }
        });
    When I have the same treepanel working and I use

    Code:
    Ext.get('ou-tree-panel').setHeight(1);
    it looks the same as in the screenshot. This gives me the impression it has something todo with the layout.

    Any help is really appreciated!

  2. #2
    Sencha - Senior Forum Manager mitchellsimoens's Avatar
    Join Date
    Mar 2007
    Location
    Gainesville, FL
    Posts
    36,755
    Vote Rating
    828
    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


    What is the parent of the treepanel like? Also, you shouldn't change the layout of the treepanel.
    Mitchell Simoens @SenchaMitch
    Sencha Inc, Senior Forum Manager
    ________________
    Check out my GitHub, lots of nice things for Ext JS 4 and Sencha Touch 2
    https://github.com/mitchellsimoens

    Think my support is good? Get more personalized support via a support subscription. https://www.sencha.com/store/

    Need more help with your app? Hire Sencha Services services@sencha.com

    Want to learn Sencha Touch 2? Check out Sencha Touch in Action that is in print!

    When posting code, please use BBCode's CODE tags.

  3. #3
    Sencha User
    Join Date
    Oct 2007
    Location
    Berlin, Germany
    Posts
    889
    Vote Rating
    9
    wm003 will become famous soon enough

      0  

    Default


    I had a similar problem. it seems it happens, when the panel is initially collapsed, thus not rendered and height not set. i solved it by adding an event which does the layout again. You still have a little lag but it works.
    PHP Code:
    ...
                                    
    listeners: {
                                        
    expand : function(p) {
                                            
    p.doLayout();                                        
                                        }
    }
    ... 

Thread Participants: 2

Turkiyenin en sevilen filmlerinin yer aldigi xnxx internet sitemiz olan ve porn sex tarzi bir site olan mobil porno izle sitemiz gercekten dillere destan bir durumda herkesin sevdigi bir site olarak tarihe gececege benziyor. Sitenin en belirgin ozelliklerinden birisi de Turkiyede gercekten kaliteli ve muntazam, duzenli porno izle siteleri olmamasidir. Bu yuzden iste. Ayrica en net goruntu kalitesine sahip adresinde yayinlanmaktadir. Mesela diğer sitelerimizden bahsedecek olursak, en iyi hd porno video arşivine sahip bir siteyiz. "The Best anal porn videos and slut anus, big asses movies set..." hd porno faketaxi