Detect an activity "replacement" transition and animate accordingly
There's an occasionally-used pattern among some apps where they
want to "replace" the current activity with another one (rather
than just open a new activity). This involves calling startActivity
and finish at the same time. It's technically more-correct to
start the new activity before calling finish; however, in practice
it kinda works (end result is same but it causes WM to do more
work) to finish before startActivity so of-course some
apps do that.
Because of this "out-of-order"ness, we end up with a CLOSE
transit which apparently looks confusing. So, this CL adds
detection for this specific scenario and treats the
transition as OPEN.
Bug: 295727324
Test: Call finish() then startActivity() immediately after.
Change-Id: I5ce06f83f00042a1cff7f32ce5beb4ab50eec191
3 files changed