Fixes issues where the PiP menu activity is out of sync.

- When the menu activity is hidden or destroyed by the system, we should
  reset the state so that we can restore the input consumer and show again
  property next time the PiP is interacted with.
- Also ensuring that non-focused pinned stack windows are not added to the
  input window list

Bug: 35462085
Bug: 34281221
Test: Relaunch a PiP activity that is single top.
Test: Launch a new task/activity from a PiP activity after
      the menu is visible.

Change-Id: I43829cce50669de704caf5a720c2adf7daf92398
2 files changed