0
votes

How to show extjs window only in a specific panel. Currently it appears on top of all panels. I have 3 tabs and I am creating and showing window in one of them. I don't want it to be visible when someone changes the tab.

1

1 Answers

1
votes

This is a simple what exactly you are looking for

Ext.onReady(function(){
  Ext.create('Ext.panel.Panel',{
 title:"Main Panel",
 layout:'hbox',
 width:600,height:300,
 tbar:[
              {text:"CreatWindow",handler:function(){
                         Ext.create('Ext.window.Window', {
                                            title: 'Renders Only in Panel1',
                                            height: 100,
                                            width: 100,                                 
                                            renderTo:'panel1'
                                        }).show();

                       }
              }
      ],
 renderTo:document.body,
 items:[
         {xtype:'panel',title:'panel1',id:"panel1",width:300,height:300},
         {xtype:'panel',title:'panel1',id:"panel2",width:300,height:300}
       ]

  });

  });