setCameraCaptureState method
{@template tmpflutter_webview_platform_interface.PlatformInAppWebViewController.setCameraCaptureState} Changes whether the webpage is using the camera to capture images or video.
NOTE for iOS: available on iOS 15.0+.
NOTE for MacOS: available on MacOS 12.0+.
Officially Supported Platforms/Implementations:
- iOS (Official API - WKWebView.setCameraCaptureState)
- MacOS (Official API - WKWebView.setCameraCaptureState) @{endtemplate}
Implementation
@override
Future<void> setCameraCaptureState({required MediaCaptureState state}) async {
Map<String, dynamic> args = <String, dynamic>{};
args.putIfAbsent('state', () => state.toNativeValue());
await channel?.invokeMethod('setCameraCaptureState', args);
}