detecting click event in DataGrid body
dg.addEventListener( "headerRelease", OnHeaderRelease );
dg.addEventListener( "cellPress", OnSelect );
dg.onPress = function(event) : Void
{
trace( "onPress - itemIndex = " + event );
};
I have a DataGrid (dg) with working event listeners on populated cells
(cellPress) and Headers (headerRelease). The DataGrid is populated dymanically,
and normally has a large unpopulated area. I need to be able to detect a mouse
click / mouse up / mouse down in the unpopulated area. The best that I've been
able to get to work is the code above, but replacing the dg.OnPress function
takes over the cellPress and headerRelease events as well. dg.onPress has no
parameters (event=undefined) so I cannot write code to re-direct to the other
handlers within onPress.
Any ideas?
|