flutter-webrtc / callkeep

iOS CallKit and Android ConnectionService for Flutter
MIT License
131 stars 142 forks source link

hasDefaultPhoneAccount give feedback about the user choice #49

Closed Pierre-Monier closed 3 years ago

Pierre-Monier commented 3 years ago

Now we can use hasDefaultPhoneAccount that way

callKeep.hasDefaultPhoneAccount(context, <String, dynamic>{
        'alertTitle': 'Permissions required',
        'alertDescription':
            'This application needs to access your phone accounts',
        'cancelButton': 'Cancel',
        'okButton': 'ok',
}).then((userHasTapedOk) {
// we can handle the case when the user refuse to give his permission
});

This will be usefull

Pierre-Monier commented 3 years ago

Also I've a question. Why the _setupAndroid method doesn't trigger the _hasDefaultPhoneAccount method ? Why we have to call the setup method and the hasDefaultPhoneAccount separately ?

cloudwebrtc commented 3 years ago

LGTM