-
Notifications
You must be signed in to change notification settings - Fork 134
Add dialing/ringing state to CallViewModel (callPickupState$)
#3466
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
Conversation
Signed-off-by: Timo K <toger5@hotmail.de>
986402c to
1b85445
Compare
waitForNotificationAnswer$)waitForNotificationAnswer$)
1b85445 to
23de483
Compare
Signed-off-by: Timo K <toger5@hotmail.de>
Signed-off-by: Timo K <toger5@hotmail.de>
23de483 to
fb8de06
Compare
waitForNotificationAnswer$)callPickupState$)
Signed-off-by: Timo K <toger5@hotmail.de>
Signed-off-by: Timo K <toger5@hotmail.de>
Signed-off-by: Timo K <toger5@hotmail.de>
Signed-off-by: Timo K <toger5@hotmail.de>
Signed-off-by: Timo K <toger5@hotmail.de>
src/UrlParams.ts
Outdated
| * - play a sound that indicates that it is awaiting an answer | ||
| * - auto-dismiss the call widget once the notification lifetime expires on the receivers side. | ||
| */ | ||
| shouldWaitForCallPickup: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is hard to find a correct naming for that :/
If I get it right it is when I start a call that will ring on the other side. And we want like a phone call experience, it should show the other user avatar/name, should give a ringing feedback, and gave up after a timeput
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right. A nitpick: we could simplify the name to waitForCallPickup. Or to clarify that the ringing is happening on the other side, perhaps waitForRemoteAnswer.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I pushed a commit changing this to waitForCallPickup for now. If anyone has a preference for something else, let me know.
| * This entails: | ||
| * - show ui that it is awaiting an answer | ||
| * - play a sound that indicates that it is awaiting an answer | ||
| * - auto-dismiss the call widget once the notification lifetime expires on the receivers side. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not sure to understand that, what does this mean "expires on the recevievers side?" Like the receiver should send some expiration signal?? Or is it a local timeout for when to stop trying to call?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My understanding is that it's a local timeout - we get to specify a duration when sending the calling event, so if we assume that the receiver respects it, we can use a local timer to approximate when their ringing stops and we should give up.
robintown
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Here's my initial review - still need to look at the newly added behaviors in more detail.
| * This entails: | ||
| * - show ui that it is awaiting an answer | ||
| * - play a sound that indicates that it is awaiting an answer | ||
| * - auto-dismiss the call widget once the notification lifetime expires on the receivers side. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
My understanding is that it's a local timeout - we get to specify a duration when sending the calling event, so if we assume that the receiver respects it, we can use a local timer to approximate when their ringing stops and we should give up.
src/UrlParams.ts
Outdated
| * - play a sound that indicates that it is awaiting an answer | ||
| * - auto-dismiss the call widget once the notification lifetime expires on the receivers side. | ||
| */ | ||
| shouldWaitForCallPickup: boolean; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right. A nitpick: we could simplify the name to waitForCallPickup. Or to clarify that the ringing is happening on the other side, perhaps waitForRemoteAnswer.
robintown
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new behaviors look correct, though I'd like to try my hand at rewriting them into a slightly more idiomatic RxJS style. Some notes on the tests as well.
robintown
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since Timo is out, I fixed up my own comments. @BillCarsonFr Would you like to review again, or do we just consider this done?
BillCarsonFr
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you can clarify the behavior change on the raise hand test
This adds a new public behavior to the call view model that represents the current waiting state when this client initiated the call. This state is described in the doc comment:
It will be used by the view to render a "waiting" screen and play a "dialing/waiting sound" (not part of this PR)
It is missing any decline state which will be added in a seperate PR.
Signed-off-by: Timo K toger5@hotmail.de