Git Product home page Git Product logo

cordovacall's People

Contributors

d-marc1 avatar david-ambientsecurity avatar dmarcs avatar schmorrison avatar serargz avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

cordovacall's Issues

Can't install plugin

Hello, whenever i launch the plug-in on my command it does exit with an error. as bellow
captureerror

Android device "recent calls" are all "Unknown"

Thanks for the component!
I have got it working well except for this one issue. All the calls I receive to my voip app are showing up as "Unknown" in the device's native Recent Calls app.

I am calling cordova.plugins.CordovaCall.receiveCall('BOB');

The incoming notification looks good:
screen shot 2018-04-20 at 10 04 11 pm

But then once it view it in the log, it's shows "Unknown" instead of "BOB":
screen shot 2018-04-20 at 10 04 24 pm

Edit: In the worst case scenario, I rather nothing show up on the "Recent Calls" log, anyway of doing this?

"Calling accounts" issue on Android 6.0

Hi, thank you so much for your awesome plugin! It works great on IOS and on Android 8+, but I have problem with activating calling accounts on Android 6.0.
Have 2 situations - where it works correct and not correct:

1. Working behaviour

  1. Lunch app first time
  2. Get incoming call
  3. As it told in plugin description about Calling accounts settings page - "On Android Oreo and above this doesn't happen anymore 😃 The Calling accounts screen gets skipped, and the native call UI is shown immediately." So for Android 6 I'll need to enable it.
  4. Try to make outgoing call.

In this case outgoing calls will work.

1. Non working behaviour

  1. Lunch app first time
  2. Try to make outgoing call

In this case 'native calling screen' will appears, plugin will use 'native phone but' it will call via sim card...To make it works through internet calls I'll need to go to my mobile calls settings/settings/Calling accounts enable them and only after that I will be able to make calls via internet.

To sum up - When you call "receiveCall" method first time it checks calling accounts and if needed cause 'Calling accounts' page and all works fine, but method sendCall method don't do it.

Maybe I miss something, but is there any way to call "Accounts list" on app start or on sendCall method for old Android 6.0 or maybe there is some other solution for this situation?

Thank you.

Which permissions needs to be allowed ?

Hi :)
Intro : I'm using android nougat 7.0 and I know that we need to allow permissions on runtime . I use a cordova pluging for that.

My problem : I get callback error when attempting CordovaCall.receiveCall()

Error : "You need to accept phone account permissions in order to send and receive calls"

My question : I looked into android Manifest and I'm confused between CALL_PHONE, GET_ACCOUNTS,READ_PHONE_STATE,ACCEPT_HANDOVER permissions. Which one/ones needed for all functionalities in this plugin ?

Thnks :)

ios call flow

@D-Marc1 @dmarcs, not an issue but curious on the authors call flow. do you guys use SIP as signalling mechanism or have your own custom signalling like SDP inside push payload.

Im asking because when using Sipjs as signalling library doing CordovaCall receiveCall to soon introduces no audio in 1 out of 4 calls. Re-arranging the flow removes the bug but results in a slower mechanism (cordovaCall receiveCall when a sip invite happens instead on push notification.

So just curious on the approach you guys use?

throw error on unsupported versions

I highly recommend providing some kind of indication that CordovaCall is unavailable on older platform versions.

This will help writing and updating version checking on both platforms.

Add custom ringtone on a Meteor app

Any Meteor users here?
How to add a custom ringtone to a Meteor app?

I've added the ringtone file in cordova-build-override/ and used App.appendToConfig(element) to declare the resource-file in mobile-config.js.
But get an error when meteor run ios-device:

Subproject Path: CordovaLibt                 |
=> Errors executing Cordova commands:         
                                              
   While adding platform iOS to Cordova project:
   Error: Source path does not exist: sounds/Bellcore-dr2.caf
(...)

Looks like Meteor reads config.xml before copying the ringtone file to the cordova directory.
Is there any straightforward way to do this in Meteor?

Thanks

app killed and calling from native log ios

not sure if its my just my build, if I kill the app and make a call from the native call log. i dont get any cordovacall event firing. it could be im using ionic wkwebview?

Control audio

Programmatically control muting and speakerphone on/off.

Endcall Function is not working no UUID

If i execute for example
cordova.plugins.CordovaCall.receiveCall('Me');

It launch OK the secreen to decline or response

If I response and call later in my app the function

cordova.plugins.CordovaCall.endCall();
Nothing happened. The native screen call is active all time and when I close my app it show "Error call"

to reproduce the error

cordova.plugins.CordovaCall.receiveCall('Me');

cordova.plugins.CordovaCall.on('answer', () => {

      setTimeout(() => { // 5 sec to end call
         cordova.plugins.CordovaCall.endCall();
      }, 5000);
  
  });

Not able to make network calls while device is locked

I'm using latest https://github.com/phonegap/phonegap-plugin-push to get some VoIP notifications. It's running well when the phone is unlocked even when the app has been killed.

But when I lock the phone, I got the cordova-call screen showing, but on answer my socket.io is not able to connect.

I already opened an issue on the plugin push repo (phonegap/phonegap-plugin-push#2245) but I think it's more related to CordovaCall than push plugin...

Did anyone get the calls working with webrtc while the screen is locked?

Here is a sample of my code:

pushObject.on('notification').subscribe(async (data: any) => {
    // even with app force closed, xcode shows this code in logs
    console.log("Push on notification", data);
    
    if (this.platform.is('ios')) {
         cordova.plugins.CordovaCall.receiveCall(data.additionalData.username);
    }
}


cordova.plugins.CordovaCall.on('answer', async () => {
     const socket = io(ENV.API_URL, {
          port: ENV.API_PORT,
          query: 'test'
     });

     socket.on('connected', () => {
          // this code never runs if the screen is locked
          // if we check in network tabs with safari open, we can see an infinite loading socket.io request
          console.log('connected');
     });
});

I need to create a socket.io connection to get ice and descriptions...

java.lang.SecurityException: PhoneAccount connection service requires BIND_TELECOM_CONNECTION_SERVICE permission

When using this plugin for android phones I get the following error after a production build:

E/AndroidRuntime: FATAL EXCEPTION: main
                  Process: com.komedhealth.frontend, PID: 6191
                  java.lang.RuntimeException: Unable to start activity ComponentInfo{com.komedhealth.frontend/com.komedhealth.frontend.MainActivity}: java.lang.SecurityException: PhoneAccount connection service requires BIND_TELECOM_CONNECTION_SERVICE permission.
                      at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2778)
                      at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2856)
                      at android.app.ActivityThread.-wrap11(Unknown Source:0)
                      at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589)
                      at android.os.Handler.dispatchMessage(Handler.java:106)
                      at android.os.Looper.loop(Looper.java:164)
                      at android.app.ActivityThread.main(ActivityThread.java:6494)
                      at java.lang.reflect.Method.invoke(Native Method)
                      at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438)
                      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807)
                   Caused by: java.lang.SecurityException: PhoneAccount connection service requires BIND_TELECOM_CONNECTION_SERVICE permission.
                      at android.os.Parcel.readException(Parcel.java:2005)
                      at android.os.Parcel.readException(Parcel.java:1951)
                      at com.android.internal.telecom.ITelecomService$Stub$Proxy.registerPhoneAccount(ITelecomService.java:1019)
                      at android.telecom.TelecomManager.registerPhoneAccount(TelecomManager.java:972)
                      at com.dmarc.cordovacall.CordovaCall.initialize(CordovaCall.java:71)
                      at org.apache.cordova.CordovaPlugin.privateInitialize(CordovaPlugin.java:57)
                      at org.apache.cordova.PluginManager.getPlugin(PluginManager.java:171)
                      at org.apache.cordova.PluginManager.startupPlugins(PluginManager.java:97)
                      at org.apache.cordova.PluginManager.init(PluginManager.java:86)
                      at org.apache.cordova.CordovaWebViewImpl.init(CordovaWebViewImpl.java:117)
                      at org.apache.cordova.CordovaActivity.init(CordovaActivity.java:149)
                      at org.apache.cordova.CordovaActivity.loadUrl(CordovaActivity.java:224)
                      at com.komedhealth.frontend.MainActivity.onCreate(MainActivity.java:39)
                      at android.app.Activity.performCreate(Activity.java:7009)
                      at android.app.Activity.performCreate(Activity.java:7000)
                      at android.app.Instrumentation.callActivityOnCreate(Instrumentation.java:1214)
                      at android.app.ActivityThread.performLaunchActivity(ActivityThread.java:2731)
                      at android.app.ActivityThread.handleLaunchActivity(ActivityThread.java:2856) 
                      at android.app.ActivityThread.-wrap11(Unknown Source:0) 
                      at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1589) 
                      at android.os.Handler.dispatchMessage(Handler.java:106) 
                      at android.os.Looper.loop(Looper.java:164) 
                      at android.app.ActivityThread.main(ActivityThread.java:6494) 
                      at java.lang.reflect.Method.invoke(Native Method) 
                      at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:438) 
                      at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:807) 

Crash on Android and not correct at all on IOS

I use this plugin for IOS and Android.

Test on iphone6s Plus, IOS11.1
IOS: Plugin cannot function normally when I sendCall and receiveCall.
CASE1 (sendCall): No screen pop up until I close my app then it pop up.
CASE2 (receiveCall):
The screen pop up normally, I click the "Accept icon" will return back my app screen and then I close my app the calling screen pop up.

Android: App will crash when I sendCall.
"test.test.test" is app name.
Android SDK: API_26
Run at Android 5.1 Lollipop

adb logcat:
E/AndroidRuntime(16600): java.lang.NoSuchMethodError: No virtual method requestPermissions([Ljava/lang/String;I)V in class Landroid/app/Activity; or its super classes (declaration of 'android.app.Activity' appears in /system/framework/framework.jar)
V/SettingsInterface( 850): from settings cache , name = send_action_app_error , value = 1
D/ViewRootImpl( 850): hardware acceleration is enabled, this = ViewRoot{20af8a0d Application Error: test.test.test,ident = 108}
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ registerInputChannel - monitor=false
V/WindowManager( 850): Changing focus from null to Window{b2187d3 u0 Application Error: test.test.test} Callers=com.android.server.wm.WindowManagerService.addWindow:2989 com.android.server.wm.Session.addToDisplay:174 android.view.ViewRootImpl.setView:641 android.view.WindowManagerGlobal.addView:289
D/InputDispatcher( 850): Focus entered window: Window{b2187d3 u0 Application Error: test.test.test}
I/WindowManager( 850): Gaining focus: Window{b2187d3 u0 Application Error: test.test.test}
I/BufferQueueConsumer( 320): Application Error: test.test.test setConsumerName: Application Error: test.test.test
I/BufferQueueConsumer( 320): Application Error: test.test.test setDefaultBufferSize: width=193 height=193
I/BufferQueueConsumer( 320): Application Error: test.test.test setDefaultBufferSize: width=1218 height=624
I/BufferQueueProducer( 320): Application Error: test.test.test connect(P): api=1 producer=(850:system_server) producerControlledByApp=false
D/BufferQueueProducer( 320): Application Error: test.test.test allocateBuffers: allocating from 0 buffers up to 4 buffers
D/BufferQueueProducer( 320): Application Error: test.test.test allocateBuffers: allocating from 4 buffers up to 4 buffers
I/BufferQueueProducer( 320): Application Error: test.test.test queueBuffer: fps=2.98 dur=1005.45 max=985.90 min=6.88
W/RefreshRateControl( 850): Open RRC Driver Error (No such file or directory)
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ prepareDispatchCycle - flags=0x00000105, xOffset=-27.000000, yOffset=-709.000000, scaleFactor=1.000000, pointerIds=0x80000000
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ startDispatchCycle
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ finishDispatchCycle - seq=47750, handled=true
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ startDispatchCycle
I/BufferQueueProducer( 320): Application Error: test.test.test queueBuffer: fps=17.13 dur=1518.05 max=1068.03 min=8.10
W/RefreshRateControl( 850): Open RRC Driver Error (No such file or directory)
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ prepareDispatchCycle - flags=0x00000105, xOffset=-27.000000, yOffset=-709.000000, scaleFactor=1.000000, pointerIds=0x80000000
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ startDispatchCycle
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ finishDispatchCycle - seq=47752, handled=true
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ startDispatchCycle
V/WindowManager( 850): Changing focus from Window{b2187d3 u0 Application Error: test.test.test EXITING} to Window{3f245d3e u0 com.sonyericsson.home/com.sonymobile.home.HomeActivity} Callers=com.android.server.wm.WindowManagerService.removeWindowLocked:3121 com.android.server.wm.WindowManagerService.removeWindow:3058 com.android.server.wm.Session.remove:193 android.view.ViewRootImpl.dispatchDetachedFromWindow:3451
I/WindowManager( 850): Losing focus: Window{b2187d3 u0 Application Error: test.test.test EXITING}
I/BufferQueueProducer( 320): Application Error: test.test.test disconnect(P): api 1
I/BufferQueueConsumer( 320): Application Error: test.test.test getReleasedBuffers: returning mask 0xffffffffffffffff
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ unregisterInputChannel
D/InputDispatcher( 850): channel 'b2187d3 Application Error: test.test.test (server)' ~ abortBrokenDispatchCycle - notify=false
D/InputDispatcher( 850): Focus left window: Window{b2187d3 u0 Application Error: test.test.test}
D/InputDispatcher( 850): Window went away: Window{b2187d3 u0 Application Error: test.test.test}
D/Dialog ( 850): handleMessage:{ when=0 what=67 obj=com.android.server.am.AppErrorDialog$2@37848bcd target=android.app.Dialog$ListenersHandler obj=com.android.server.am.AppErrorDialog$2@37848bcd }

Nice plugin and thank you review it.

Samsung Audio

Hello,

I'm having trouble with local audio not working after an incoming sip invite is answered with the call kit. I'm kind of stumped b/c its only happening on Samsung phones. The same code/plugin works great on my pixel 2 and iOS.

As far as I can tell, neither the call kit or the sip session is muting the microphone in any way.

I'm also having a similar problem to #33 but I'm not sure if it related to the audio. After accepting a call with the kit interface, my app is brought to the foreground, then after about a second the call kit is pulled back to the foreground in the connected state. No calling accounts page. While it's not ideal, I can work around this b/c android lets you resume apps in the background.

Any help is appreciated.

Problem on device with Asus call manager like on Zen Phone

On some Zen phone the UI is managed by Asus call manager (some third party dialer) and it causes issue with audio handling with Webrtc. I could get it to work with a delay of 10 seconds to get the audio started. The first call seem to work instant but subsequent seems to need that delay. I dont know what that Asus call manager thing does but it does some weird stuff, like your able to record the audio and stuff.

Anyone seeing this on these devices? or its just me?

Also interesting comment i found and the thread have some good ideas, will attempt to do a PR in the future if someone does not beat me to it
twilio/voice-quickstart-android#95

off('event') or unsubscribe

I'm receiving different calls by push notification, with different params for each of them:

     pushObject.on('notification').subscribe((data: any) => {
          cordova.plugins.CordovaCall.receiveCall(data.additionalData.username);

          cordova.plugins.CordovaCall.on('answer', () => {
              this.handleDeeplink(data);
          });
      });

As I'm setting the CordovaCall.on('answer') at every push reception, I need to unbind it before setting it again. But I don't think there is a off() method.

Or maybe there is another way of handling it?

Thanks!

fail while build

After installing the plugin i receive. Build fails even before entering the code. Just after the install.

/Users/user/MyProjects/cordova/dialer/platforms/android/src/com/dmarc/cordovacall/CordovaCall.java:66: error: cannot find symbol
if(android.os.Build.VERSION.SDK_INT >= android.os.Build.VERSION_CODES.O) {

Removing Facetime Icon

Just wondering if there is a way to remove this Facetime icon or insert another place holder in place?

At first receiveCall, sound will be muted.

I'm using jssip, iosrtc and CordovaCall, I did a receiveCall but no sound at first receiveCall.(There is no sound for caller and callee). It's works well at second receiveCall and I have no error without CordovaCall.

Thanks for your review:)

"Choose SIM for this call" Dialog when placing regular calls

Hey guys thanks for the awesome work!

On android, every time I try and make a call from the native contacts or recents, I see a dialog which asks me to "Choose SIM for this call", with 2 options: make a call with my carrier SIM, or with my calling cordova app.

On some devices I've tested there is no option to choose a default, so this is triggered on every single call, which makes this issue a blocker for us.

Is there a way to get around this?

Thanks!

Can't set speakerphone on/off at first call.

I'm using webrtc and CordovaCall, I tried to set speakerphone on/off by cordova-plugin-audioroute or cordova-plugin-audiotoggle, but not functional at first receiveCall. Second receiveCall works well.

I have no error without receiveCall.

HTC One A9 - Call rejected immediately on Android 6.0

Hi, thank you for your plugin. On iOS it works fine. But on Android I have the following sequence of events when notification received:

  1. receiveCall success callback
  2. onReceiveCall
  3. onReject

And than a missed call in notification center. Sometimes 2 and 3 events appears twice in one call. The same behavior in foreground and background mode.

I allowed incoming internet calls in Settings, but there are no applications in Accounts, as you described in docs. So maybe it is a problem. When internet calls have been disallowed, I've been receiving the connection screen, but call has been rejected immediatelly without my interaction, but at least I seen it.

There is a code:

// initialization
function initCordovaCall() {
	if ( cordova.plugins.CordovaCall ) {
		cordovaCall = cordova.plugins.CordovaCall;
		cordovaCall.setIncludeInRecents(true);
		cordovaCall.on('sendCall', function() {
			console.log('onSendCall');
		});
		cordovaCall.on('receiveCall', function() {
			console.log('onReceiveCall');
		});
		cordovaCall.on('answer', function() {
			console.log('onAnswer');
		});
		cordovaCall.on('reject', function() {
			console.log('onReject');
		});
		cordovaCall.on('hangup', function() {
			console.log('onHangup');
		});
	}
}

// push notification handler
push.on('notification', function(data) {
	cordovaCall.setVideo(false);
	cordovaCall.receiveCall('John Doe', '1234567', function() {
		console.log('receiveCall success callback');
	}, function(err) {
		console.log('receiveCall error: ' + err);
	});
});

All permissions for my app are allowed (Camera, Microphone, Phone, Storage). Maybe I need to ask for some other permissions on Android? I use Phonegap Build for this project.

Thank you.

VoIP app is missing from stock Contacts app on iOS

Hi,

looks like this plugin should support this feature when voip app can be opened (called via) from ios contacts but it does not work for me...

please see how WhatsApp is added to the list on this screenshot as example
img_0432

is this something that can be done by updating supportedHandleTypes with CXHandleTypePhoneNumber or I'm just missing some configuration to make it work?

thank you!

package.json entry crashes npm install

Hello

The plugin puts two lined in package.json:

{
    "dependencies": {
        ......
        "com.dmarc.cordovacall": "~1.0.4"
    },
    .......
    "cordova": {
        "com.dmarc.cordovacall": {}
    }
}

The dependencies injection causes npm install to fail, because the package com.dmarc.cordovacall is non-existant in the npm registry.

$ npm install
npm ERR! code E404
npm ERR! 404 Not Found: com.dmarc.cordovacall@~1.0.4

Thanks for any help with this.

Error with iOS 12

When I call the plugin like this:

cordova.plugins.CordovaCall.sendCall(
            'Mami',
            () => {
                console.log('XXX success');
                // simulate your friend answering the call 5 seconds after you call
                setTimeout(() => {
                    cordova.plugins.CordovaCall.connectCall(
                        () => {
                            console.log('XXX CONNECT CALL sucess');
                        },
                        error => {
                            console.log('XXX CONNECT CALL ERR');
                            console.log(error);
                        }
                    );
                }, 5000);
            },
            err => {
                console.log('XXX error');
                console.log(err);
}

I get the following error on my iPad with iOS 12: AVAudioSessionPortImpl ValidateRequiredFields: Unknown selected data source for Port Speaker

Airpods issue

Hi dmarcs,

After receive a phone call by CordovaCall, voice broadcast from speaker when I use airpods(bluetooth headset). How can I broadcast from my airpods?

How to show "ongoing call" UI after call got accepted?

How to show "ongoing call" UI after call got accepted? At the moment the plugin automatically shows the normal cordova app but I would like to show the native "ongoing call" UI so the user sees that the call is on going.

Can't use cordova-plugin-background-mode

Hi all,
All Questions are on IOS 11, test on real phone(iphone6s plus).
Question 1
I'm using cordova-plugin-background-mode with CordovaCall, the following are my pseudo code:
1: cordova.plugins.backgroundMode.enable();
2: Coming Call.
3: cordova.plugins.CordovaCall.receiveCall("jwliang2226");
4: User press "ACCEPT" to chat.
5: cordova.plugins.CordovaCall.endcall();
6. User press iphone power button to sleep.
7. Javascript into sleep(??)
8. Someone call is coming but Javascript is sleeping, so Callkit can not start!
cordova.plugins.backgroundMode.enable() not function anymore, even I do it again, background can not be re-enable.

Question 2
cordova.plugins.CordovaCall.on('answer', function() {
/* I will into "answer event" several times when I accept a receiveCall once. */
console.log("Into answer event");
});

Question 3
I'm using jssip and cordova-plugin-iosrtc with this plugin(CordovaCall), I do cordova.plugins.CordovaCall.receiveCall() and local streaming(iphone camera) is works perfectly at first time, but do cordova.plugins.CordovaCall.receiveCall at several time the local streaming(iphone camera) will show black screen.(Can't open camera successfully)

[debug log]
[avas] AVAudioSession.mm:1177:-[AVAudioSession setActive:withOptions:error:]: Deactivating an audio session that has running I/O. All I/O should be stopped or paused prior to deactivating the audio session.

I have no error without CordovaCall plugin. When I use CordovaCall plugin I can't release my camera device?

My camera release code:
var selfView = document.getElementById('localVideo');
var remoteView = document.getElementById('remoteVideo');
selfView.pause();
remoteView.pause();
selfView.src = "";
remoteView.src = "";
session.connection.getLocalStreams()[0].getTracks()[0].stop();
remoteStream.getTracks()[0].stop();

I have no error without CordovaCall plugin and release code.

Thanks for your review:)

UI not showing in Android

I tried using the UI in Android 5.1.1 but nothing showed (not even the err cb gets called).

cordova.plugins.CordovaCall.sendCall('fdaf', 'rwerqwerew', function(){}, function(){ console.log(arguments); } )

help

Sorry can you give me a little example for how to use this plug-in, i'm really bad sorry.

PhoneGap Build Error for Android

PGB could not build the last version of CordovaCall for Android. Please, see the PGB log attached.

/src/com/dmarc/cordovacall/CordovaCall.java:68: error: cannot find symbol
                  .setCapabilities(PhoneAccount.CAPABILITY_SELF_MANAGED)
                                               ^
  symbol:   variable CAPABILITY_SELF_MANAGED
  location: class PhoneAccount
/src/com/dmarc/cordovacall/CordovaCall.java:171: error: cannot find symbol
                  .setCapabilities(PhoneAccount.CAPABILITY_SELF_MANAGED)
                                               ^
  symbol:   variable CAPABILITY_SELF_MANAGED
  location: class PhoneAccount
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
2 errors
:compileReleaseJavaWithJavac FAILED

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':compileReleaseJavaWithJavac'.
> Compilation failed; see the compiler error output for details.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Total time: 36.795 secs
Error: /gradlew: Command failed with exit code 1 Error output:
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
/src/com/dmarc/cordovacall/CordovaCall.java:68: error: cannot find symbol
                  .setCapabilities(PhoneAccount.CAPABILITY_SELF_MANAGED)
                                               ^
  symbol:   variable CAPABILITY_SELF_MANAGED
  location: class PhoneAccount
/src/com/dmarc/cordovacall/CordovaCall.java:171: error: cannot find symbol
                  .setCapabilities(PhoneAccount.CAPABILITY_SELF_MANAGED)
                                               ^
  symbol:   variable CAPABILITY_SELF_MANAGED
  location: class PhoneAccount
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
Note: Some input files use unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
2 errors

FAILURE: Build failed with an exception.

Android / Choose SIM for this call

Hi there,

We're having issues when we try to call contacts from outside the app with android 8/9 on with a samsung s7 edge (android 8) and essential phone ph1 (android 9).

sans-titre-1

Our app won't be able to handle "normal" calls so how could we disable this modal to open?

Thanks again guys!

call forwarding

I need call forwarding for one project, there are any function to acomplish this?

Plugin initialize crashes app on Android 5.x (fix included)

Plugin's initialize routine uses PhoneAccount.CAPABILITY_CALL_PROVIDER which is only available in Android M (SDK 23+), which causes a crash on Android 5.x.

https://developer.android.com/reference/android/telecom/PhoneAccount.html#CAPABILITY_CALL_PROVIDER says: "added in API level 23".

While the plugin can be 'used' only on Android M+, it should be possible to 'include' it in apps supporting older versions of Android. App can have OS version checks to decide when to use this plugin's functionality or not.

Fix is to add a

        if (android.os.Build.VERSION.SDK_INT >= 23) {

Around both instances of

            phoneAccount = new PhoneAccount.Builder(handle, appName)
                    .setCapabilities(PhoneAccount.CAPABILITY_CALL_PROVIDER)
                    .build();
            tm.registerPhoneAccount(phoneAccount);

Full Patch for the fix (only adds two if conditions):

diff --git a/cordova-call/src/android/CordovaCall.java b/cordova-call/src/android/CordovaCall.java
index fcb5966..f7f66ea 100644
--- a/cordova-call/src/android/CordovaCall.java
+++ b/cordova-call/src/android/CordovaCall.java
@@ -70,10 +70,12 @@ public class CordovaCall extends CordovaPlugin {
                   .build();
           tm.registerPhoneAccount(phoneAccount);
         }
-        phoneAccount = new PhoneAccount.Builder(handle, appName)
-                 .setCapabilities(PhoneAccount.CAPABILITY_CALL_PROVIDER)
-                 .build();
-        tm.registerPhoneAccount(phoneAccount);
+        if (android.os.Build.VERSION.SDK_INT >= 23) {
+            phoneAccount = new PhoneAccount.Builder(handle, appName)
+                    .setCapabilities(PhoneAccount.CAPABILITY_CALL_PROVIDER)
+                    .build();
+            tm.registerPhoneAccount(phoneAccount);
+        }
         callbackContextMap.put("answer",new ArrayList<CallbackContext>());
         callbackContextMap.put("reject",new ArrayList<CallbackContext>());
         callbackContextMap.put("hangup",new ArrayList<CallbackContext>());
@@ -177,10 +179,12 @@ public class CordovaCall extends CordovaPlugin {
                   .build();
               tm.registerPhoneAccount(phoneAccount);
             }
-            phoneAccount = new PhoneAccount.Builder(handle, appName)
-                 .setCapabilities(PhoneAccount.CAPABILITY_CALL_PROVIDER)
-                 .build();
-            tm.registerPhoneAccount(phoneAccount);
+            if (android.os.Build.VERSION.SDK_INT >= 23) {
+                phoneAccount = new PhoneAccount.Builder(handle, appName)
+                    .setCapabilities(PhoneAccount.CAPABILITY_CALL_PROVIDER)
+                    .build();
+                tm.registerPhoneAccount(phoneAccount);
+            }
             this.callbackContext.success("App Name Changed Successfully");
             return true;
         } else if (action.equals("setIcon")) {

Add Ionic Support

  • Hide webView when receiveCall, sendCall, connectedCall are used to show the CallKit native UI

Adding [self.webView setBackgroundColor:[UIColor clearColor]]; to receiveCall works, but not for the others.

Can't configure Calling Account on Android 7

I'm trying to user Cordova Call plugin on my Ionic 3 webrtc app using PeerJS, when I receive a call it redirects me to the Calling Accounts Settings, I did set Use Internet Calling => For all call, e selected the Receive Internet Calls but it keep me asking to create an internet calling account, but none was set for CordovaCall

Any help here?

Error on sendCall function

I always get this error
The operation couldn’t be completed. (com.apple.CallKit.error.requesttransaction error 7.)fail

I'm using the lastest version of S.O and xCode

Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.