active method

  1. @override
Future<List<NativeIncoming>> active()
override

Calls the native UI knows about (Android: the last one). accepted is set when the user accepted it — e.g. the tap that launched the app.

Implementation

@override
Future<List<NativeIncoming>> active() async {
  final calls = await FlutterCallkitIncoming.activeCalls();
  return [
    for (final c in calls)
      NativeIncoming(uuid: c.id, callId: '${c.extra?['callId'] ?? ''}', name: c.nameCaller ?? '', handle: c.handle, accepted: c.isAccepted),
  ];
}