TreeGrid v6.0

Mouse API

TreeGrid documentation index

 

 

API event          bool       OnClick                 (TGrid grid, TRow row, string col, int x, int y, Event event)                       chg 6.0 .

Called after click to cell [row, col]. row and col are never null.

x, y is click position inside the cell.           event is standard JavaScript MouseEvent to get for example information about Ctrl/Alt/Shift keys or other information about click.

Return true to suppress default OnClick action

 

API event          bool       OnDblClick        (TGrid grid, TRow row, string col, int x, int y, Event event)                                     .

Called after double click to grid. row or col can be null for double click outside the cells.

x, y is click position inside the cell.           event is standard JavaScript MouseEvent.

Return true to suppress default OnDblClick action

 

API event          bool       OnRightClick (TGrid grid, TRow row, string col, int x, int y, Event event)                                     .

Called after right click to grid. row or col can be null for double click outside the cells.

x, y is click position inside the cell.           event is standard JavaScript MouseEvent.

Return true to suppress default OnRightClick action

 

API event          bool       OnMouseDown         (TGrid grid, TRow row, string col, int x, int y, Event event)                .

Called after mouse down in grid. row or col can be null for double click outside the cells.

x, y is click position inside the cell.           event is standard JavaScript MouseEvent.

Return true to suppress default OnRightClick action

 

API event          bool       OnMouseUp    (TGrid grid, TRow row, string col, int x, int y, Event event)                                     .

Called after mouse up in grid. row or col can be null for double click outside the cells.

x, y is click position inside the cell.           event is standard JavaScript MouseEvent.

Return true to suppress default OnMouseUp action

 

API event          bool       OnMouseMove          (TGrid grid, TRow row, string col, int x, int y, Event event)                .

Called after whenever mouse moves above grid. row or col can be null for double click outside the cells.

only very short code here to not slow down the grid.

x, y is click position inside the cell.           event is standard JavaScript MouseEvent.

Return true to suppress default OnMouseMove action

 

API event          void       OnMouseOver            (TGrid grid, TRow row, string col, TRow orow, string ocol, Event event)         .

Called after whenever mouse enters to another cell or outside any cell or row.

row or col is new cell, the orow, ocol is old cell. All parameters except grid can be null.

event is standard JavaScript MouseEvent.

 

global func.      TGrid    Grids.Active                                                                                                                                          ,

Pointer to active grid under the mouse cursor. It processes mouse wheel events.

 

API variable      TRow    ARow          read only                                                                                                                                   .

Actual row under mouse cursor or null

 

API variable      string    ACol             read only                                                                                                                                   .

Actual column under mouse cursor