Fixing issue with wrong stack being brought forward.

- Ensure that we only check the supoprtsPictureInPictureWhilePausing
  state when the activity state is actually pausing.

Bug: 35872668
Test: android.server.cts.ActivityManagerPinnedStackTests
Change-Id: If63b16919e1f4e8fb555a349809a9cdf2af7499b
1 file changed