mirror of
https://github.com/revanced/revanced-integrations.git
synced 2024-11-30 15:52:55 +01:00
feat(remove-screen-capture-restriction): remove app constraint (#411)
Co-authored-by: oSumAtrIX <johan.melkonyan1@web.de>
This commit is contained in:
parent
fa44f1227b
commit
31251f0214
@ -0,0 +1,21 @@
|
||||
package app.revanced.all.screencapture.removerestriction;
|
||||
|
||||
import android.media.AudioAttributes;
|
||||
import android.os.Build;
|
||||
|
||||
import androidx.annotation.RequiresApi;
|
||||
|
||||
public final class RemoveScreencaptureRestrictionPatch {
|
||||
// Member of AudioAttributes.Builder
|
||||
@RequiresApi(api = Build.VERSION_CODES.Q)
|
||||
public static AudioAttributes.Builder setAllowedCapturePolicy(final AudioAttributes.Builder builder, final int capturePolicy) {
|
||||
builder.setAllowedCapturePolicy(AudioAttributes.ALLOW_CAPTURE_BY_ALL);
|
||||
|
||||
return builder;
|
||||
}
|
||||
|
||||
// Member of AudioManager static class
|
||||
public static void setAllowedCapturePolicy(final int capturePolicy) {
|
||||
// Ignore request
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue
Block a user