startRecordScreen static method

Future<bool> startRecordScreen(
  1. String name, {
  2. String? titleNotification,
  3. String? messageNotification,
})

Implementation

static Future<bool> startRecordScreen(String name,
    {String? titleNotification, String? messageNotification}) async {
  try {
    if (titleNotification == null) {
      titleNotification = "";
    }
    if (messageNotification == null) {
      messageNotification = "";
    }

    await _maybeStartFGS(titleNotification, messageNotification);
    final bool start = await FlutterScreenRecordingPlatform.instance.startRecordScreen(
      name,
      notificationTitle: titleNotification,
      notificationMessage: messageNotification,
    );

    return start;
  } catch (err) {
    print("startRecordScreen err");
    print(err);
  }

  return false;
}