Hi,
 I am using an AdvancedDataGrid where I allow the user to drag and
drop datagrid columns to an area(top-section) above the datagrid. This
works fine but when a user drops a column in top-section the columns
reordering in the datagrid also takes place. That is if the user drags
the fifth column to top section in such a way that the fifth column
falls directly above the second column, the fifth column becomes the
second column.
  I want to have a logic where if a user drags a column to the top
section the column reordering should be disabled. If he drags the
column to any other column inside the datagrid, reordering
should work.

 For this I tried to stop the event propagation for the
MouseEvent.MOUSE_UP for both the datagrid and datagridheaderrenderer.
But this did not work. I observed that if I stop the propagation of
MouseEvent.MOUSE_DOWN the reordering stops working. But I cannot use
MouseEvent.MOUSE_DOWN as I do not know where the column has been
dragged to in this event. Also in the AdvancedDataGridBaseEx class it
looks like the code for reordering is inside the mouseUpHandler but I
am not able to stop it execution. I have tried other events like
DragEvents and DataGridEvent.HEADER_RELEASE but none seems to work.

Please let me know on how I could achieve this.

TIA
GAurav

Reply via email to