Merge "Refactor dispatching the focus event from handleWindowFocusChanged" into tm-qpr-dev