Skip to content

[Android] Add support of self managed call #310

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from
Closed

[Android] Add support of self managed call #310

wants to merge 1 commit into from

Conversation

luxiliu
Copy link

@luxiliu luxiliu commented Nov 2, 2020

The changes in this pull request is to support self managed ConnectionService.

Screen Shot 2020-11-03 at 11 00 35 am

Example app is updated to show how to use it.

  1. Set selfManaged of IOptions to true.
  2. Add RNCallKeep.addEventListener('showIncomingCall', youMethodToShowIncomingCall)
  3. Implement your own logic In youMethodToShowIncomingCall

@luxiliu luxiliu changed the title Add support of self managed call [Android] Add support of self managed call Nov 2, 2020
@sboily
Copy link
Member

sboily commented Nov 2, 2020

Hello, it could be great to have a README fo this new feature for explaining what is it and how to use it.

@luxiliu
Copy link
Author

luxiliu commented Nov 3, 2020

Hello, it could be great to have a README fo this new feature for explaining what is it and how to use it.

👌 Comment is updated above 👆

@danwhite-ipc
Copy link

Does this solution handle all app state scenarios? ie when the app is in the background or dead?

@luxiliu
Copy link
Author

luxiliu commented Nov 6, 2020

Does this solution handle all app state scenarios? ie when the app is in the background or dead?

I'm not sure. I think this change is not related to whether app state is background or dead. It just implements https://developer.android.com/reference/android/telecom/Connection#onShowIncomingCallUi(), and expose a callback for RN app.

@wilau2
Copy link

wilau2 commented Nov 21, 2020

Does this solution handle all app state scenarios? ie when the app is in the background or dead?

It probably does not handle the scenarios you have in mind..
You'll have to make sure, that your incomingCall activity have the window flags:

        getWindow().addFlags(WindowManager.LayoutParams.FLAG_SHOW_WHEN_LOCKED | WindowManager.LayoutParams.FLAG_TURN_SCREEN_ON);

But in order for this to work, you will have to make sure that the activity that you set those flags on will be destroyed and created again when needed.

This is the only way that we've been able to have the incoming call screen always display on top of the keyguard.

@sboily
Copy link
Member

sboily commented Nov 27, 2020

We need to make some tests before merge this PR, but if there is not objections, i think we could merge it after the tests. @manuquentin and @danjenkins any objections about this new features?

@danjenkins
Copy link
Collaborator

@sboily Totally!

@marcato15
Copy link

And progress on this?

@luxiliu
Copy link
Author

luxiliu commented Jan 26, 2021

How's the tests going?

@sboily
Copy link
Member

sboily commented Feb 15, 2021

Hello, sorry we don't have find time to start the test... We'll do as soon as possible.

@sboily sboily added the need review Need to review ticket label Feb 19, 2021
@sboily sboily added waiting for feedback Waiting for feedback and removed need review Need to review ticket labels Apr 15, 2021
@luxiliu
Copy link
Author

luxiliu commented Apr 16, 2021

Closing as #395 is created

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
waiting for feedback Waiting for feedback
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants