How do I allow the document to listen for the space button being pressed (and call the function) but prohibit scrolling when the mouse is centered in a scroll section? (Hitting space bar should still call the function even if pressed in a scroll section).
$(document).keydown(function(e){
if (e.keyCode==32 && !$(e.target).is("input")) {
if (active.getState() === "act") {
nogo();
} else if (active.getState() === "unact") {
go();
}
}
});