public TalkView( Guid id, CityView city, SpeakerView speaker, DateTime startsAt, TalkStatus status, string name, string comment, string shortInfo, string fullInfo, DateTime?approvedAt, AdministratorView approvedBy, DateTime?placeVerifiedAt, AdministratorView placeVerifiedBy, PlaceView place, DateTime?publishedAt, AdministratorView publishedBy, DateTime?reportedAt, AdministratorView reportedBy, string report) { Id = id; City = city; Speaker = speaker; StartsAt = startsAt; Status = status; Name = name; Comment = comment; ShortInfo = shortInfo; FullInfo = fullInfo; ApprovedAt = approvedAt; ApprovedBy = approvedBy; PlaceVerifiedAt = placeVerifiedAt; PlaceVerifiedBy = placeVerifiedBy; Place = place; PublishedAt = publishedAt; PublishedBy = publishedBy; ReportedAt = reportedAt; ReportedBy = reportedBy; Report = report; }
/// <summary> /// Handler for the TSConnection's TalkStatusChanged Event /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void TsConnection_TalkStatusChanged(object sender, TS3QueryLib.Core.Client.Notification.EventArgs.TalkStatusEventArgs e) { string name; if (this.clients.ContainsKey(e.ClientId)) { name = this.clients[e.ClientId].Name; } else { name = "UNKNOWN"; } logger.Trace("TalkStatusChanged: {0} {1}", name, e.TalkStatus); TalkStatus internalStatus = TalkStatus.Unknown; switch (e.TalkStatus) { case TS3QueryLib.Core.Client.Notification.Enums.TalkStatus.TalkStarted: internalStatus = TalkStatus.TalkStarted; break; case TS3QueryLib.Core.Client.Notification.Enums.TalkStatus.TalkFinished: internalStatus = TalkStatus.TalkStopped; break; default: break; } this.RaiseTalkStatusChanged(new Data.TalkStatusEventArgs(e.ClientId, name, internalStatus, e.IsWisper)); }
public TalkStatusEventArgs(uint clientId, string clientName, TalkStatus status, bool isPrivate) { this.ClientID = clientId; this.ClientName = clientName; this.Status = status; this.IsPrivate = isPrivate; }
/// <summary>トークスピード</summary> public void SpeedClick() { Debug.Log("speedClick"); m_talkStatus++; switch (m_talkStatus) { case TalkStatus.StandardSpeed: break; case TalkStatus.DoubleSpeed: m_speedText.text = "×2"; m_waitTime /= 2; break; case TalkStatus.HalfSpeed: m_speedText.text = "×0.5"; m_waitTime *= 4; break; case TalkStatus.Last: m_speedText.text = "×1"; m_waitTime /= 2; m_talkStatus = TalkStatus.StandardSpeed; break; } }
private static void updateClientIconBasedOnActivity(Client client, TalkStatus status = TalkStatus.NotTalking) { switch (status) { case TalkStatus.Talking: { mainForm.updateClientIconBasedOnActivity(client, true); break; } default: { mainForm.updateClientIconBasedOnActivity(client, false); break; } } }
private static void UpdateApplicationIconBasedOnActivity(TalkStatus status) { switch (status) { case TalkStatus.Talking: { mainForm.UpdateApplicationIconBasedOnActivity(true); break; } default: { mainForm.UpdateApplicationIconBasedOnActivity(false); break; } } }
private static void Connection_TalkStatusChanged(Client client, TalkStatus status, bool isReceivedWhisper) { try { string verb = status != TalkStatus.NotTalking ? "starts" : "stops"; Console.WriteLine($"TalkStatus: {status.ToString()}"); Console.WriteLine($"Client {client.Nickname} {verb} talking."); Console.WriteLine($"Client uID: {client.UniqueIdentifier}"); if (client == Connection.Self) { UpdateApplicationIconBasedOnActivity(status); SelfTalkStatus = status; } // Update clients icon in channel list updateClientIconBasedOnActivity(client, status); } catch (NullReferenceException) { // Do nothing, client disconnected } }
/// <summary> /// This event is called when a client starts or stops talking. /// </summary> /// <param name="client">the client who announced the talk status change</param> /// <param name="status">the state of the voice transmission</param> /// <param name="isReceivedWhisper">true if this event was caused by whispering, false if caused by normal talking</param> private static void Connection_TalkStatusChanged(Client client, TalkStatus status, bool isReceivedWhisper) { string verb = client.IsTalking ? "starts" : "stops"; Console.WriteLine($"Client {client.Nickname} {verb} talking."); }
/// <summary> /// This event is called when a client starts or stops talking. /// </summary> /// <param name="client">the client who announced the talk status change</param> /// <param name="status">the state of the voice transmission</param> /// <param name="isReceivedWhisper">true if this event was caused by whispering, false if caused by normal talking</param> private void Connection_TalkStatusChanged(Client client, TalkStatus status, bool isReceivedWhisper) { string verb = client.IsTalking ? "starts" : "stops"; AppendToLog($"Client {client.Nickname} {verb} talking."); }
private void Connection_TalkStatusChanged(Client client, TalkStatus status, bool isReceivedWhisper) { update_client_info(client); }
public Option <Talk> FindTalkFor(Guid speakerId, TalkStatus status) => Query(t => t.SpeakerId == speakerId) .Where(t => t.Status == status) .FirstOrDefault().SomeNotNull();