Commit graph

50 commits

Author SHA1 Message Date
David Baker
e43adef438 firefox uses 'address' instead of 'ip' 2021-01-26 10:52:35 +00:00
David Baker
ec0266d82b Log candidates for calls
First attempt at this was sending everything from
RTCPeerConnection.getStats() as a separate item in the rageshake,
but the rageshake server doesn't handle that in a particularly sensible
way and it's probably better to pick & choose what data we want explicitly
from a privacy PoV. This summarises the candidates used for the calls into
the log that will be included in rageshakes so we can diagnose connectivity
issues from rageshakes.

Requires https://github.com/matrix-org/matrix-js-sdk/pull/1584
2021-01-26 09:41:57 +00:00
David Baker
303694754b
Merge pull request #5572 from matrix-org/dbkr/dont_play_hangup_sound_when_answered_elsewhere
Don't play the hangup sound when the call is answered from elsewhere
2021-01-25 16:39:44 +00:00
David Baker
8783765ce3 Don't play the hangup sound when the call is answered from elsewhere 2021-01-25 16:18:14 +00:00
David Baker
0a90c982c7 Add VoIP user mapper
The accompanying element-web PR with the config documentation should
explain what this is & why. Internally, this breaks the assumption
that call.roomId is the room that the call appears in for the user.
call.roomId may now be a 'virtual' room while the react SDK actually
displays it in a different room. React SDK always stores the calls
under the user-facing rooms, and provides a function to get the
user-facing room for a given call.
2021-01-21 19:20:35 +00:00
David Baker
452fbb076b Add a dialpad UI for PSTN lookup
Queries the homeserver for PSTN protocol support, and if found,
the add-room button on the DM rooms list section opens a context
menu instead with a 'dial pad' option as well as the current 'start chat'
dialog. Entering a number into this and pressing dial performs
a thirdparty user query for the given string and starts a DM with that
user.
2020-12-23 19:02:01 +00:00
David Baker
68c5482c05
Comment typo
Co-authored-by: J. Ryan Stinnett <jryans@gmail.com>
2020-12-21 11:21:41 +00:00
David Baker
12474bb434 Merge remote-tracking branch 'origin/develop' into dbkr/call_ui_fixups 2020-12-21 11:10:31 +00:00
David Baker
eab764a3c8 Vary resume link text
Use 'Switch' if unholding that call would hold another
2020-12-18 19:35:41 +00:00
David Baker
453575d70a Don't play call end sound for calls that never started 2020-12-18 13:46:58 +00:00
David Baker
973a0b7b8a set dispatcher ref to null so we don't double-unregister 2020-12-16 10:53:59 +00:00
David Baker
a77d675664 Better null check
to make tests happy
2020-12-15 18:01:42 +00:00
David Baker
a798772e80 Unregister from the dispatcher in CallHandler
otherwise you end up getting multiple place_call dispatches if you
place a call after logging in
2020-12-15 16:53:11 +00:00
David Baker
5282c6bbe8 Merge remote-tracking branch 'origin/develop' into dbkr/line_1_2 2020-12-10 12:36:11 +00:00
Lukas
a856484139 Fix typos in some strings
This commit fixes some typos that I've stumbled upon.
2020-12-06 10:32:52 +01:00
David Baker
4c50125e9d Don't remove call when we call hangup
as hopefully explained by comment
2020-12-04 20:22:01 +00:00
David Baker
1ce63f0fa7 Line 1 / 2 Support
Support one active call plus one call on hold
2020-12-03 17:45:49 +00:00
David Baker
3a3775b523 Only show 'answered elsewhere' if we tried to answer too
and don't play the hangup tone

Fixes https://github.com/vector-im/element-web/issues/15735
2020-11-30 15:17:20 +00:00
David Baker
522c2d9dc7
Typo
Co-authored-by: J. Ryan Stinnett <jryans@gmail.com>
2020-11-27 14:03:52 +00:00
David Baker
65ab0ee665 Slightly better error if we can't capture user media
Fixes https://github.com/vector-im/element-web/issues/15837
2020-11-27 12:53:09 +00:00
David Baker
37059a3fcd Move call listener out of MatrixChat
and into callhandler
2020-11-23 16:20:15 +00:00
David Baker
cf2d8d2f1f Wrench createNewMatrixCall straight out of call
rather than importing browser-index
2020-11-05 17:59:02 +00:00
David Baker
9be3ce928f explicitly retuen null
and also sort out formatting from a different time
2020-11-05 09:47:43 +00:00
David Baker
7796621e8d Merge remote-tracking branch 'origin/develop' into dbkr/call_hold 2020-10-30 16:49:42 +00:00
David Baker
f828c6d494 Implement call hold
Currently just by adding /holdcall and /unholdcall slash commands

The only place the hold status of the call is currently represented
is when the call is a voice call and you're viewing a different room:
it's not wired up when you're viewing the room because that currently
uses the room status bar which it won't do with the new UI.

Also convert VideoFeed to typescript, and remove videoview because
it essentially just managed the fullscreen functionality, but we'll
want and 'on hold' representation (and probably chrome for hagnup etc)
in the fullscreen UI too, so let's just make CallView the thing that
gets fullscreened.
2020-10-29 17:56:24 +00:00
Michael Telatynski
c3a355097d Initial Countly work 2020-10-29 15:57:16 +00:00
David Baker
765fdf93e6 Support 'answered elsewhere'
Show a dialog for now, telling the user someone beat them to it.

Only useful with https://github.com/matrix-org/matrix-js-sdk/pull/1522
(but can be merged safely without).
2020-10-21 11:54:48 +01:00
David Baker
88b7210f5c consistent quotes 2020-10-19 15:04:57 +01:00
David Baker
45d639d963 Add analytics to VoIP 2020-10-19 14:56:15 +01:00
David Baker
4a26199a75
use real equals
Co-authored-by: Travis Ralston <travpc@gmail.com>
2020-10-16 20:28:20 +01:00
David Baker
7ad366603a Support rejecting calls
Use the 'reject' method when we want to reject an incoming call
rather than end one that's in progress. Also get our error messages
right for the other side rejecting the call (albeit still with
placeholder dialog-box UX).

Requires https://github.com/matrix-org/matrix-js-sdk/pull/1510
2020-10-15 14:54:03 +01:00
David Baker
54babddb38 Support glare for VoIP calls
The js-sdk supports glare but we didn't support it, which means the
js-sdk will still do glare but we didn't know about it, leaving the
UI in horribly broken states where the js-sdk would be on a call but
the app didn't think it was.

Fixes https://github.com/vector-im/element-web/issues/5770
2020-10-13 15:08:23 +01:00
David Baker
414901dfae More enums 2020-10-12 11:38:32 +01:00
David Baker
abd5e3b3cf More enums 2020-10-12 10:25:23 +01:00
David Baker
3af7abb5fe This comment is no longer true 2020-10-12 09:56:43 +01:00
David Baker
94802036d9 AudioId -> AudioID 2020-10-12 09:55:21 +01:00
David Baker
55f77b04ae Rewrite call state machine
* Remove the two separate enumerations of call state: now everything
   uses the js-sdk version of call state. Stop adding a separate
   'call_state' field onto the call object(!)
 * Better reflection of the actual state of the call in the call bar,
   so when it's connecting, it says connecting, and only says 'active call'
   when the call is actually active.
 * More typey goodness
2020-10-09 18:56:07 +01:00
Travis Ralston
cca9b91aca
Merge pull request #5171 from matrix-org/travis/widget-api
Switch to using the Widget API SDK for widget messaging
2020-10-01 10:16:01 -06:00
David Baker
648b93c133
Merge pull request #5267 from matrix-org/dbkr/fix_call_preview
Fix the call preview when not in same room as the call
2020-10-01 11:44:39 +01:00
David Baker
a45b7e50cd Fix the call preview when not in same room as the call
Classic failure of an ES6 map also being a regular object :(

Fixes https://github.com/vector-im/element-web/issues/15343
2020-10-01 11:28:42 +01:00
Travis Ralston
f27071ee64 Transition all remaining messaging over (delete the old stuff) 2020-09-30 20:20:31 -06:00
Travis Ralston
b46f58274e Fix the hangup button and other custom actions 2020-09-30 20:09:23 -06:00
Travis Ralston
555bcc6010 Document remaining (known) cases to fix 2020-09-29 15:32:18 -06:00
Travis Ralston
bfa269a848 Update copy 2020-09-29 10:20:54 -06:00
Travis Ralston
a20d2af102 Incorporate changes into new call handler 2020-09-28 13:53:44 -06:00
David Baker
eb0a4a5fb9 type the action payload 2020-09-24 18:30:30 +01:00
David Baker
10338798d9 map-ify audioPromises 2020-09-24 18:28:46 +01:00
David Baker
4269c26e76 map-ify calls map 2020-09-24 18:18:26 +01:00
David Baker
adc93ca7d6 add ts-ignore for js-sdk as per comment 2020-09-24 16:42:59 +01:00
David Baker
8962f7ae9e Convert CallHandler to typescript
and remove the old conference call stuff while we're at it: enough
time should have passed since those mistakes that we can move on.
The old conference call rooms will still appear for anyone whose
account dates back to that time, but they've presumably been appearing
in any other matrix client they used too.
2020-09-24 16:16:20 +01:00