Cell cell = view.getCellForEvent(event);
int row = cell.getRowIndex();
int col = cell.getCellIndex();

OR

private int getRowForEvent(MouseEvent<?> event)
    {
        Element td =
getEventTargetCell(Event.as(event.getNativeEvent()));
        if (td == null)
        {
            return -1;
        }

        Element tr = DOM.getParent(td);
        Element tbody = DOM.getParent(tr);
        int row = DOM.getChildIndex(tbody, tr);

        return row;
    }

On Sep 21, 4:24 am, Ivan <[email protected]> wrote:
> Hi all,
>
>     I've searched much document about how to get the row index and
> column index on mouse over event, but i'still have no idea about that.
>     Can you give me some example code tell me how to do that ?
>
>     I can get element like below step, but how do i to get row index
> and column index ?
>
>         public void onBrowserEvent(Event event) {
>                 Element td = getEventTargetCell(event);
>         }
>
>     Thank you.

-- 
You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.

Reply via email to