Revert 57094 - Making window.focus()/blur() work only when there is a user gesture.

Also making window.focus() select tab if it is not visible.
The RenderViewHost now calls ActivateContent and the new DeactivateContent (instead of using the recently added TabContentsDelegate::Activate/Deactivate methods which have been removed).

BUG=29643,52346
TEST=Create a page with buttons that call window.focus()/blur() directly and with a timeout. When called directly, the calls should succeed (the browser should be activated/deactivated). When called with a timeout, nothing should happen. Also test that a popup calling window.opener.focus() cause the opening tab to become selected when it is not the current tab.

Review URL: http://codereview.chromium.org/3156016

[email protected]
Review URL: http://codereview.chromium.org/3201008

git-svn-id: svn://svn.chromium.org/chrome/trunk/src@57105 0039d316-1c4b-4281-b951-d872f2087c98
23 files changed