Fix reporting HOT launch state while required to restart process

We were reporting the launch state as HOT whenever brought a task
to top, even the process was gone. Now we check if the activity
is attached to its process to judge the launch state.

Bug: 126182006
Test: atest ActivityMetricsLoggerTests

Change-Id: I3dfc54ddf27732384c4a5425c321812667313b50
2 files changed