Allow the event trap to receive focus in read-only mode

A disabled element is not able to become the document's activeElement.
The better way of setting the event trap to non-editable is through
the readOnly flag. This still allows focus to be passed to the trap.

During a mouse down event, the event trap should be disabled however
to ensure it doesn't capture the window selection.
Re-enable the event trap if a context menu is displayed

A contextmenu event is fired instead of a mouseup event, therefore
both these events need to be listened for to ensure the event trap
becomes re-enabled.