flutter-webrtc / callkeep

iOS CallKit and Android ConnectionService for Flutter
MIT License
137 stars 150 forks source link

Extracting UI responsibility, named parameters, android dismissal fix #189

Closed mikaelwills closed 3 months ago

mikaelwills commented 3 months ago

Three main fixes:

Android calling UI wasn't being dismissed when answerIncomingCall() was being called from in app UI. needed to call setCurrent() in native android.

I spent ages trying to figure out why things weren't working only to realise i was passing the caller name into the handle parameter. Added named parameters to all functions so that shouldnt happen for anyone in the future and things are clearer.

In recent versions of flutter the framekwork suggest against passing BuildContexts across async gaps also your app should be responsible for how it looks not an external package. For the default permissions UI i've extracted out the responsibility so the app using the package can determine how that dialog looks.

Also some updates to the readme!