osx - detecting altKey on MacOS in zoomchart -


i'm implementing functionality create link between 2 nodes on shift+alt+click. this

function graphselectionchange(event){ var selection = event.selection; if (selection.length === 2 && event.altkey){     var fromitem=selection[0];     var toitem=selection[1];     chart.adddata({         links:[{             "id":"ll"+nextid,             from:fromitem.id,              to:toitem.id,             "style":{"label":"newlink"}             }]         });     nextid += 1;     } }  

the altkey seems not detected. according http://jsfiddle.net/rw4km/ alt/option button on keyboard. clue?

use click event (it has selection attribute).

selection event not have altkey property.

there other selection changes, selected nodes disappearing, not have associated mouse clicks not want link added in such case.


Comments

Popular posts from this blog

hibernate - How to load global settings frequently used in application in Java -

python 3.x - Mapping specific letters onto a list of words -

objective c - Ownership modifiers with manual reference counting -