Hello, I’m trying to open the contextMenu by using the shortcutManager. My goal would be to allow the use of the ContextMenu key, but I can’t find the method to open it.
Thank you for any help!
Here is my code :
componentDidMount() {
console.log('EditorTable: componentDidMount');
const hot = this.getHotInstance();
const gridContext = hot.getShortcutManager().getContext('grid');
gridContext.addShortcut({
group: 'group_ID',
runOnlyIf: () => hot.getSelected() !== void 0,
keys: [['n']],
callback: () => {
// TODO
},
});
this.listenToElectronEvents();
}