isLockScreen method

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

This method is used to get screen is from locked state or not.

Implementation

@override
Future<bool> isLockScreen() async {
  bool? res;
  try {
    res = await mirrorFlyMethodChannel.invokeMethod<bool>('isLockScreen');
    LogMessage.d("isLockScreen", res);
    return res ?? false;
  } on PlatformException catch (e) {
    LogMessage.d("Platform Exception =", " $e");
    return res ?? false;
  } on Exception catch (e) {
    LogMessage.d("Exception ", " $e");
    return res ?? false;
  }
}