Changed the constraints for hiding the top controls

Currently, for hiding the top controls we check if the IME is
hidden. But with that we cannot prevent the top controls from
hiding while using a physical keyboard and the input field is
focused by the js. Instead we should check if any input field
is focused in the content and disallow hiding of top controls.

BUG=504355

Review URL: https://codereview.chromium.org/1209243003

Cr-Commit-Position: refs/heads/master@{#337783}
6 files changed