PDA

View Full Version : BUG / HELP with dragndrop Organizer example



reignman
23 Feb 2007, 10:10 AM
Hey guys,

I was using the code of the tree.organizer example.

I had a View element like in the example.

Now I wanted to add a toolbar in the same Panel where the view should be.
so I crated a child in the imgBody element for the toolbar and for the View.

no problem: loading view and toolbar worked fine.

BUT then I realized that DragnDrop didn't work anymore.
you can try it within your own organizer example by changing following code


var view = new Ext.JsonView(imgBody, tpl, {
multiSelect: true,
jsonRoot: 'images'
});

to

var view = new Ext.JsonView(imgBody.createChild({tag:'div'}), tpl, {
multiSelect: true,
jsonRoot: 'images'
});

reignman
23 Feb 2007, 10:39 AM
small extension.
now it works.. but think it's still kind of bug with dragndrop.

It only works if View was build upon a ContentPanels.getEl().

So what I did:


var nviewEl = new Ext.ContentPanel(imgBody.createChild({tag:'div'}), {
title:'Liste',
fitToFrame:true,
autoScroll:true,
autoCreate:true
});
var view = new Ext.JsonView(nviewEl , tpl, {
multiSelect: true,
jsonRoot: 'images'
});