Add contact preferences announcement
Persist contact options and announce them on chat connection and reconnection. Prepare the audio-only call contract; enforcement and audio-only media remain unimplemented. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This commit is contained in:
parent
0886b5e4e7
commit
9c4cce6840
11 changed files with 150 additions and 5 deletions
|
|
@ -4,6 +4,7 @@ namespace Yavsc.Abstract.Chat.Calls;
|
|||
|
||||
public static class CallHubMethods
|
||||
{
|
||||
public const string SetContactPreferences = "SetContactPreferences";
|
||||
public const string Invite = "InviteCall";
|
||||
public const string InviteLan = "InviteLanCall";
|
||||
public const string Accept = "AcceptCall";
|
||||
|
|
@ -15,9 +16,18 @@ public static class CallHubMethods
|
|||
public const string SignalReceived = "CallSignal";
|
||||
}
|
||||
|
||||
public sealed record ContactPreferences(bool AllowAudioCalls, bool AllowVideoCalls, bool AllowPrivateMessages);
|
||||
|
||||
public enum CallDisplayMode
|
||||
{
|
||||
AudioVideo,
|
||||
AudioOnly
|
||||
}
|
||||
|
||||
public sealed record CallSession(
|
||||
Guid Id, string RoomName, string Caller, string Callee, bool RelayOnly,
|
||||
DateTimeOffset ExpiresAt, string Transport = CallTransports.WebRtc);
|
||||
DateTimeOffset ExpiresAt, string Transport = CallTransports.WebRtc,
|
||||
CallDisplayMode DisplayMode = CallDisplayMode.AudioVideo);
|
||||
|
||||
public static class CallTransports
|
||||
{
|
||||
|
|
|
|||
Loading…
Reference in a new issue