PDA

View Full Version : Error panel constrain: true



fabio.policeno
19 Jun 2013, 4:54 AM
Hello,


Necessary to allow the child to be dragged panel only in the region of its owner, for it used the constrain: true, but is not working properly, as I show in the video, when you release, it is not in the correct position.


Ext.create('Ext.panel.Panel', { width: 400,
height: 200,
renderTo: Ext.getBody(),
items: [{
width: 50,
height: 50,
draggable: true,
constrain: true
},{
width: 50,
height: 50,
draggable: true,
constrain: true
}]
});


http://screencast.com/t/bIdRu44I

Thank's!

skirtle
19 Jun 2013, 7:21 PM
Perhaps the same as this?

http://www.sencha.com/forum/showthread.php?261054

Songle
19 Jun 2013, 11:07 PM
Try using windows rather than panels (your default xtype). I had heaps of issues getting panels to constrain correctly but windows worked perfectly. I assumed it was a bug as mentioned.