toggleScreenshot method

  1. @override
Future<bool> toggleScreenshot()
override

Return true if screenshot capabilities has been successfully toggle from it previous state and false if the attempt to toggle failed. throw UnmimplementedError if not implement

Implementation

@override
Future<bool> toggleScreenshot() async {
  _isProtectionOn ? _disableProtection() : _enableProtection();
  return true;
}