Restrict sending new intent to one invocation.

A special condition, where the new intent is delivered outside
the normal logic flow, was extended to included documents as well.
This can lead to any intent marked with the document launch flag
sending the intent in this block as well as the normal flow.

This changelist restricts the number of times the intent can be
sent to once during each activity start.

Change-Id: If1e62527d260cbe5ff170680695b03d9de532c09
Fixes: 67367621
Test: open Photos link in gmail twice
Test: cts/hostsidetests/services/activityandwindowmanager/util/run-test CtsAppTestCases android.app.cts.NewDocumentTest
1 file changed