Support ActivityViews

Add an app:shouldRestoreFocus attribute and setShouldRestoreFocus()
method to FocusParkingView for use in an ActivityView. This makes the
FocusParkingView allow itself to be focused by the framework rather than
finding some other view to focus.

This prevents multiple views from being focused when an application with
an ActivityView is launched, one inside the ActivityView and one
outside.

Bug: 171334003
Bug: 171425596
Bug: 171425519
Test: replace maps with test activity, then nudge in and out
Test: replace maps with test activity, then nudge and rotate within it
Test: replace maps with test activity, then press Home button via rotary
Test: atest com.android.car.ui.FocusParkingViewTest
Test: atest com.android.car.ui.FocusParkingViewTouchModeTest
Change-Id: I3557e47c4b61f8936b629efbcf9adaa90e1c2c31
3 files changed