Fix subwindows' content on ESC key press

Since subwindows are just QDialogs in QMdiArea, we need to patch
their key events, so they would not close themselves on ESC key
press. We can do so with our own method for adding them into the
QMdiArea, which installs our patched event filter on the target.
This is a tricky, yet working solution.