mlsoft.mct.MlGridEvent

Event
    MlGridEvent

This class contains the detail for a Grid event. The Grid will send the following events for the following reasons:

Event Type (id)       Called When
CELL_FOCUS_IN         Cell gains focus
CELL_FOCUS_OUT        Cell loses focus
DESELECT_CELL         Cell is deselected
DESELECT_COLUMN       Column is deselected
DESELECT_ROW          Row is deselected
EDIT_BEGIN            Cell edit begins
EDIT_CANCEL           Cell edit is canceled
EDIT_COMPLETE         Cell edit is complete
EDIT_INSERT           Cell edit insert begins
RESIZE_ROW            Row is resized
RESIZE_COLUMN         Column is resized
SCROLL_ROW            Grid is scrolled (vertically) to a new row
SCROLL_COLUMN         Grid is scrolled (horizontally) to a new column
SELECT_CELL           Cell is selected
SELECT_COLUMN         Column is selected
SELECT_ROW            Row is selected
SELECT_ACTIVATED      Cell is activated with Return or double-click
In the JDK 1.1, this class is a subclass of java.awt.AWTEvent, containing AWTEvent member variables along with the additional row and/or column information about the event. The structure of this class is basically:
    public class MlGridEvent extends AWTEvent
    {
    public int rowType;
    public int row;
    public int columnType;
    public int column;
    public AWTEvent originalEvent;
    }
So you can access the various AWTEvent fields (id, consumed, etc.) as well as the row and column position of the event.

For Java Beans, you should use the accessor methods to obtain the row and column information instead of accessing the public member variables. For example, to access the rowType, use getRowType() instead of accessing the rowType public member variable.

Public Methods

public int getType()
Returns type of the event. Refer to Event Type in the above table for the full list of types.

public int getColumn()
Returns the column associated with the event.

public int getColumnType()
Returns the type of the column associated with the event. This may be one of MlGrid.HEADING, MlGrid.CONTENT or MlGrid.FOOTER.

public int getRow()
Returns the row associated with the event.

public int getRowType()
Returns the type of the row associated with the event. This may be one of MlGrid.HEADING, MlGrid.CONTENT or MlGrid.FOOTER.

public Object getSource()
Returns the MlGrid source of this event.

public Object getOriginalEvent()
Returns the original event which caused the MlGridEvent.