ExtJS. Hide all components within a container

前端 未结 3 1941
一个人的身影
一个人的身影 2021-01-06 13:39

I have a window in which I am rendering a number of components like panels etc.

Is there a way I can hide all the components contained in window without having to hi

3条回答
  •  [愿得一人]
    2021-01-06 14:02

    If I understood you right, you do not want to hide your window, but the elements in your window. So can do this:

    // get window, get element, get all direct children with css selector '*'
    var children = Ext.get('myWindow').getEl().down('*')
    
    // hide them all
    Ext.each(children,function(child){child.hide();});
    

提交回复
热议问题