Fix problem with context-menu paste not triggering saving of edits

We'll use the input event to detect changes, which is reliable but
doesn't work on older browsers