Fix 29887 take 2
This is the more generic version of https://github.com/mono/monodevelop/pull/995 where the TextEditor has implemented the IKeyHandler interface, which the command manager then checks to see if the text editor is currently overriding the key press.
Fixes the issues where Escape wouldn't close the Insert Extracted Method overlay, or wouldn't close the autocompletion dialog if it was assigned to a command. (Bug 29887)
It also prevents essential keys from being overridden if they are assigned to a command such as alphanumeric keys or Tab, Return or Backspace.
This lgtm.
It looks ok to me. @mkrueger can you review?
I think that shadows a problem somewhere else. It used to work AFAIK. What about other components than the text editor ?
Other than that it'll work that way. But it looks like we're digging a hole here that gets deeper :/. However I don't know enough about the command manager problem and how it can be resolved. Merge if really nothing other will help.