PDA

View Full Version : How can i access Ext.dd.StatusProxy method setStatus()?



timTaylor
4 Apr 2012, 10:05 AM
The following situation:
I have a TreeView, where the user can drop items via the 'treeviewdragdrop' plugin from a GridView.
On dragging an item from the grid over an existing item at the tree, I have to give a visual feedback if drop is allowed or not.
See my code below to get an Idea what I want to do ...


Ext.override(Ext.dd.DragSource, {

afterDragOver : function(target, e, id)
{
var me = this;
var v = target.view;
var cell = e.getTarget(v.cellSelector);
if(cell)
{
var row = v.findItemByChild(cell);
var outputObj = {
target   : target,
node     : cell,
dragData : this.dragData,
record   : v.getRecord(row)
};

var dragproxy = // ?? where can i get the dragProxy object ??
dragproxy.setStatus( this.dropNotAllowed );

v.fireEvent('onDragOverItem', outputObj);
}
}
});

timTaylor
4 Apr 2012, 10:12 AM
I've found the solution in between :-)



me.proxy.setStatus( this.dropNotAllowed );