Only make the event trap editable if the document is in edit mode

Various browser menus (cut, delete) should only enable if the document is currently in edit mode.