only capture keys from the canvas when it has focus