1. #1
    Sencha User
    Join Date
    Jul 2011
    Posts
    3
    Vote Rating
    0
    bubble8426 is on a distinguished road

      0  

    Default Unanswered: Why the the whole page disappeared after I insert or add components to another ?

    Unanswered: Why the the whole page disappeared after I insert or add components to another ?


    Why the the whole page disappeared after I insert or add components to another ?
    I have encountered this problem many times. And the reason the page disappear is that the height of dom elements become zero. If I reset their height in firebug one by one, they will show up again, including the new components I inserted/added.

    Now, I am suffering from the same problem again.
    I load several comments into a comment container as following:

    Code:
    commentStore.load({
    callback:function(store){
    Ext.suspendLayouts();
    Ext.each(store, function(record){
    var comment = Ext.getCmp('commentContainer').add({
    xtype:'comment'
    }); //Set the contents, user photo etc. to the comment //It will add new items to the comment.
    }); Ext.resumeLayouts(true);
    }
    });
    The comment container:
    Code:
    {
    xtype:'container',
    defaults:{
    flex:1
    },
    layout:{
    type:'vbox',
    align:'center',
    padding:10
    }
    }
    The only way to prevent the problem is to give the container a specific height.
    But I hope it can resize to the contents automatically.
    I try to set autoHeight to true, but it's not working.
    Can anybody help?

  2. #2
    Sencha User
    Join Date
    Jul 2011
    Posts
    3
    Vote Rating
    0
    bubble8426 is on a distinguished road

      0  

    Default


    Sorry, I don't know how to increase the height of the code region. The code below maybe more readable.

    comment loading:

    commentStore.load({
    callback:function(store){
    Ext.suspendLayouts();

    Ext.each(store, function(record){
    var comment = Ext.getCmp('commentContainer').add({
    xtype:'comment'
    });
    //Set the contents, user photo etc. to the comment
    //It will add new items to the comment.
    });

    Ext.resumeLayouts(true);
    }
    });

    comment container:


    {
    xtype:'container',
    defaults:{
    flex:1
    },
    layout:{
    type:'vbox',
    align:'center',
    padding:10
    }
    }

Tags for this Thread

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