PDA

View Full Version : ExtJS resizable Container/Panel don't change position, resize from left/top



webxells
12 Jun 2012, 6:30 AM
If I have something like this:

var container = Ext.create('Ext.container.Container', {
plain:true,
width : 300,
height: 300,
html: 'Super',
cls:'container',
renderTo:Ext.getBody(),
draggable:true,
closable:false,
resizable:{
pinned:true,
dynamic:true
}
}).center();

the container is "resizable", but will only resize on the right and bottom (south, east) side. If I resize the container on the left or top side, the container will not move, it stands on the same position. How to deal with that? If I take a window it change the position too.For example:




var win = Ext.create('Ext.window.Window', {
plain:true,
width : 300,
height: 300,
html: 'Super',
cls:'container',
renderTo:Ext.getBody(),
draggable:true,
closable:false,
resizable:{
pinned:true,
dynamic:true
}
}).center().show();

Does the job. But I will use a container. How to do this?

scottmartin
22 Jun 2012, 12:39 PM
You can can add floating: true to allow for this.

Scott.

webxells
26 Jun 2012, 4:38 AM
Indeed it's floating :>. I was searching for a long time, googling it, but no results.