mirror of https://github.com/MISP/MISP
chg: [generic_popover] Pressing <ESC> destroy the popover
parent
593f58ad09
commit
3d69620148
|
@ -1439,7 +1439,13 @@ function openPopover(clicked, data) {
|
|||
var popoverTitle = popover.find('h3.popover-title');
|
||||
popoverTitle.html(title + closeButtonHtml);
|
||||
})
|
||||
.popover('show');
|
||||
.popover('show')
|
||||
.on('keydown.volatilePopover', function(e) {
|
||||
if(e.keyCode == 27) { // ESC
|
||||
$(this).popover('destroy');
|
||||
$(this).off('keydown.volatilePopover');
|
||||
}
|
||||
});
|
||||
} else {
|
||||
// $clicked.popover('show');
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue