setFlashlight method

Future<void> setFlashlight(
  1. bool enabled
)

Turns the flashlight (torch) on or off.

Implementation

Future<void> setFlashlight(bool enabled) async {
  await _channel.invokeMethod('hardware.setFlashlight', {'enabled': enabled});
}