Hi Adrian,

Thanks for the response.  So I didn't know about the hideDropFeedback
method on the ListBase class.  That helps a bit but the problem I'm
encountering now, is that when I start dragging, it denies it at
first, but once it passed over a row that it's able to drop, it
becomes droppable over all the rows.  It looks like the
DragManager.acceptDragDrop() toggles on and won't turn back off even
if I hide the dragDropFeedback.  Is there a method like
DragManager.rejectDragDrop() so that when I'm dragging a row over all
the rows, that it will reject certain rows, but accepts others?

Thanks

s.park

--- In [email protected], Adrian Williams <adri...@...> wrote:
>
> Hi,
> 
> We handle something very similar to this, and although we don't deny a 
> drop based on the index, we use the index to persist the drop location 
> in the database...the same logic applies.  We are using this on an ADG 
> and hence my example below:
> 
> You could grab the internal targetGrids dropData get the 
> dropData.index...check it and if its not the value you want, perform an 
> event.preventDefault and stopPropagation...
> 
> private function adg_DragEvent(event:DragEvent):void
> {
>     var targetGrid:AdvancedDataGrid = event.currentTarget as 
> AdvancedDataGrid;
> 
>     use namespace mx_internal;
>     var dropData:Object = targetGrid.mx_internal::_dropData;
> 
>     adgIndex = dropData.index;
> 
>     if (adgIndex > 4)
>     {
>         targetGrid.hideDropFeedback(event);
>         targetGrid.selectedItems = new Array();
>         event.preventDefault();
>         event.stopPropagation();
>     }
> }
>       
> HTH!
> Adrian
> 
> 
> park96 wrote:
> >
> > Anyone have an example of how to deny a drop based on the drop index?
> > The problem I'm facing is that even though my dragEnter event handler
> > doesn't call the DragManager.acceptDragDrop(UIComponent), it still
> > allows me to drop it.
> >
> >
>


Reply via email to