How can I catch the F5 key press when the mouse is outside my page?
For example hovering on a scroll bar, or on an address bar, or on a menu etc.
Because in this case e.which
, which usually contains 116
for F5, contains undefined
EDIT: After playing with Alexey Lebedev' jsfiddle I discovered that if the last user click was inside my page, I actually can catch F5.
However if the last user click was outside my page, the problem remains.
I would think the browser client area is not in focus, but then it should not get the keypress and should not be refreshed at all.