var line = new Kinetic.Line({ points: [415, 115,617,234], stroke: 'gray', tension: 2});
line.addEventListener('click',function(e){
debugger;
// alert(e.x+'.'+ e.y);
// popup;
});
On clicking the line it should be selected.on clicking other place expect line it should be deselected.after selecting the line if i pressed a delete button the line should get destroyed how to do it.
Not exact as your requirement, but you double click on line, line will be removed from layer
here is demo.