Wait for home visible before resuming app switches

The part that sets the stop-app-switches time from pressHomeButton()
might race with resumeAppSwitches(), so waiting for home visible before
calling the latter. That *might* be the cause of the flakiness in the
bug. However, if it isn't I believe this change doesn't hurt.

Test: atest BackgroundActivityLaunchTest
Bug: 134733754
Change-Id: Ie128b658ee427e0931cfa2cb4bf2b1e7a071357b
1 file changed