ConnectyCube / connectycube-flutter-call-kit

A Flutter plugin for displaying call screen when the app in the background or terminated.
https://developers.connectycube.com/flutter
Apache License 2.0
56 stars 76 forks source link

Timeout, callback #140

Open a7mdragab opened 6 months ago

a7mdragab commented 6 months ago

Dears, Is there any way to detect timeout and make call back btn appear?

Thanks in advance

TatankaConCube commented 6 months ago

in the current realisation required feature is unavailable. you can try to implement it by yourself using the callback onCallIncoming/onCallIncomingWhenTerminated where you can start your timer and after timer is over you can cancel the call notification and display your own with the required buttons.

coreyfreeman82 commented 3 months ago

I tried using the onCallingIncoming callback but it didn't seem to execute. I have: ConnectycubeFlutterCallKit.instance .init(onCallAccepted: _onCallAccepted, onCallRejected: _onCallRejected, onCallIncoming: _onCallIncoming); The accepted and rejected callbacks work but the call incoming did never seem to trigger. I assume this should trigger when I show the callkit using ConnectycubeFlutterCallKit.showCallNotification(callEvent);

TatankaConCube commented 3 months ago

the callbacks onCallIncoming/onCallIncomingWhenTerminated will be executed in a case when the plugin shows CallKit by itself by the push notification. if you show the CallKit by yourself it means that you know when you start to do it, and you can start your timer there.