The listener not working when app is terminated in the new version, and in the last version was working fine, but in the last days stopped from working.
static Future<void> onAppStart(
BuildContext context,
) async {
await checkAndNavigationCallingPage();
CallKeep.instance.handler = CallEventHandler(
onCallIncoming: (event) {
final callParams = AgoraCallModel.fromNotificationData(
event.toMap()["extra"],
);
activateIncomingCallListener(
callParams.channelName,
event.uuid,
);
},
onCallAccepted: (event) {
final callParams = AgoraCallModel.fromNotificationData(
event.toMap()["extra"],
);
return _onCallAccepted(
context,
callParams: callParams,
);
},
onCallDeclined: (event) {
//todo: add a callback when the call is rejected
final callParams = AgoraCallModel.fromNotificationData(
event.toMap()["extra"],
);
return _onCallRejected(
context,
callParams: callParams,
);
},
);
}
The listener not working when app is terminated in the new version, and in the last version was working fine, but in the last days stopped from working.
and i call this method in the initstate for the app.dart file