disableScreenCapture method

  1. @override
Future<void> disableScreenCapture()
override

Disables screen capture (screenshots and recordings) on supported platforms.

Throws a PlatformException if the operation fails.

Implementation

@override
Future<void> disableScreenCapture() async {
  try {
    await methodChannel.invokeMethod('disableScreenCapture');
  } on PlatformException catch (e) {
    throw 'Failed to disable screen capture: ${e.message}';
  }
}