Skip to content
Commit 89e8322f authored by Naomi Musgrave's avatar Naomi Musgrave
Browse files

(1/N)[MediaProjection] Throw exception if token re-used

Validate if the IMediaProjection token (representing
the user's consent) is used to get more than one
MediaProjection instance, or if client app is trying to
invoke MediaProjection#createVirtualDisplay more than
once.

Throw an exception for target SDK U+.

Follow-on CLs will:
* Re-show the permission dialog for re-used consent,
  when the target SDk is below U.
* Black out recording when waiting for consent

Bug: 242833866
Test: atest FrameworksServicesTests:MediaProjectionManagerServiceTest
Test: atest FrameworksServicesTests:DisplayManagerServiceTest

Change-Id: I1fc7c9afde63ea1fc849015932a66b9321879fd9
parent d9fc7a57
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment