Fix some voice interaction CTS due to regressions

- There are actually four things that control the assist data request:
  current app allowed, app ops, disabled context/secure settings, and
  requested context. The previous refactor had accidentally removed the
  check for the secure settings (user disabled context).  This CL adds
  back the check for the user disabled context.
- In addition, it tried to simplify the callbacks by merging the requested
  context and the disabled context into a single state, but the owners
  still expected a callback when a context was requested (even if not
  allowed).  This change will always ensure a callback in that case.
- Also fix small error where we didn't clear the pending data/screenshot
  after processing

Bug: 68759932
Bug: 68762521
Test: com.android.server.am.AssistDataRequesterTest
Test: #testCanNotHandleReceivedData_expectNoCallbacks
Test: #testProcessPendingData
Test: CtsVoiceInteractionTestCases
Test: CtsAssistTestCases

Change-Id: I60e049a6bf835fe726bc1133f2f8c9712bec8626
Signed-off-by: Winson Chung <winsonc@google.com>
4 files changed