When handling events on widgets in a FlexTable, sometimes I also need
to get the row/cell for that widget.

I saw this method at
http://code.google.com/p/gwt-dnd/source/browse/trunk/DragDrop/demo/com/allen_sauer/gwt/dragdrop/demo/client/FlexTableRowDragController.java?r=92&spec=svn92

private int getWidgetRow(Widget widget, FlexTable table) {
    for (int row = 0; row < table.getRowCount(); row++) {
      for (int col = 0; col < table.getCellCount(row); col++) {
        Widget w = table.getWidget(row, col);
        if (w == widget) {
          return row;
        }
      }
    }

If this is the best solution, would you please add native support for
FlexTable to get row/cell for a given widget?

Thanks!

--

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


Reply via email to