Re: [flexcoders] positioning custom drag item next to mouse cursor

2006-07-20 Thread Pan Troglodytes
This does not work for the problem.  Unfortunately, when you have custom renderers, event.target is no longer always DataGridItemRenderer.  In the example, the dragged item will be a UITextField when you click on the text and drag it.  If you click and drag the area of the cell to the right afte

Re: [flexcoders] positioning custom drag item next to mouse cursor

2006-07-20 Thread Pan Troglodytes
Thanks for your reply, but this is really the opposite of what I was looking for.  I want the mouse cursor to be at the *bottom right* of the drag feedback image.On 7/20/06, Scotty Scott <[EMAIL PROTECTED]> wrote: How about...    if (event.buttonDown) {   

Re: [flexcoders] positioning custom drag item next to mouse cursor

2006-07-20 Thread Scotty Scott
Totally missed your second requirement somehow.Change yourif (row != null)toif ((event.target is DataGridItemRenderer) && !( event.target.data is DataGridColumn))ScottyOn 7/20/06, Scotty Scott <[EMAIL PROTECTED]> wrote:How about...     if (event.buttonDown) {  var dragInitiator:Data

Re: [flexcoders] positioning custom drag item next to mouse cursor

2006-07-20 Thread Scotty Scott
How about...    if (event.buttonDown) {  var dragInitiator:DataGrid = DataGrid(event.currentTarget);  var ds:DragSource = new DragSource();  var row:Object = dragInitiator.selectedItem;   if (row != null) {    var draggedItem:Object = {label:r

[flexcoders] positioning custom drag item next to mouse cursor

2006-07-20 Thread Pan Troglodytes
Ok, I'm trying to make my dragged grid item look a certain way and am running into two problems.  I'm dragging a grid row to a list.  But I don't want the default behavior of the giant grid row.  I want my own custom drag widget and I want it to pop up with its bottom right point at the current