Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit b66babbf authored by Adam He's avatar Adam He
Browse files

Disable content capture for system apps.

Change-Id: I58f827bd2b6da63768d670f2a3e40f7d2cd003e6
Fixes: 121045049
Test: manual verification
Test: atest CtsContentCaptureServiceTestCases # still passing
parent 40335c1b
Loading
Loading
Loading
Loading
+3 −1
Original line number Diff line number Diff line
@@ -1023,7 +1023,9 @@ public class Activity extends ContextThemeWrapper
     *
     * @return The content capture manager
     */
    @NonNull private ContentCaptureManager getContentCaptureManager() {
    @Nullable private ContentCaptureManager getContentCaptureManager() {
        // ContextCapture disabled for system apps
        if (getApplicationInfo().isSystemApp()) return null;
        if (mContentCaptureManager == null) {
            mContentCaptureManager = getSystemService(ContentCaptureManager.class);
        }