SMART datagrid v.1 > Classes > GridBase

[ grids ver.1.3.5]   Back  Forward

DataLudi.GridBase.onPopupMenuPopup  event

It will be fired just before displaying the popup menu. 

If explicitly return false within this event handler, it will not display the menu. Just before displaying Context menu, it will call onContextMenuPopup event. And, if click the menu item in which has not specified callback, onPopupMenuClicked event will be fired. 

function onPopupMenuPopup (grid: GridBase, target: Object|CellIndex, menu: String|PopupMenu): Boolean|String|PopupMenu;
Returns
Boolean|String|PopupMenu
Parameters
grid - GridBase.
target - Object|CellIndex.
menu - String|PopupMenu.
Code -1
    grid.onPopupMenuPopup = function (grid, target, menu) {
        // If target is CellIndex
        if (target.rowIndex % 2 == 1) return false;
    };
See Also
Menu Overview
onPopupMenuClicked
onContextMenuPopup
Examples
Column Popup Menu
Grid Context Menu