public virtual bool Equals(ChatID other) { if (object.ReferenceEquals(other, null)) { return false; } if (object.ReferenceEquals(other, this)) { return true; } if (!string.IsNullOrEmpty( this.DialogID) && !string.IsNullOrEmpty( other.DialogID)) { return (this.DialogID == other.DialogID); } return (string.IsNullOrEmpty(this.DialogID) && string.IsNullOrEmpty(other.DialogID) && base.Equals((ContactID)other)); }
public virtual bool Equals(ChatID other) { if (object.ReferenceEquals(other, null)) { return(false); } if (object.ReferenceEquals(other, this)) { return(true); } if (this.IsRttChat != other.IsRttChat) { return(false); } return(base.Equals((ContactID)other)); }
public virtual bool Equals(ChatID other) { if (object.ReferenceEquals(other, null)) { return false; } if (object.ReferenceEquals(other, this)) { return true; } if (this.IsRttChat != other.IsRttChat) { return false; } return base.Equals((ContactID)other); }
public void MarkChatAsRead(ChatID chatId) { VATRPChat chat = FindChat(chatId); if (chat != null) { chat.UnreadMsgCount = 0; OnConversationUnReadStateChanged(chat); if ( chat.Contact != null ) { chat.Contact.UnreadMsgCount = 0; } _linphoneSvc.MarkChatAsRead(chat.NativePtr); } }
public VATRPChat FindChat(ChatID chatID) { if (chatID == null) return null; lock (this._chatItems) { foreach (VATRPChat chatItem in this._chatItems) { if ((chatItem != null) && chatItem == chatID) { return chatItem; } } } return null; }
public void ClearChatMsgs(ChatID chatID) { if (chatID != null) { VATRPChat chat = this.FindChat(chatID); if (chat != null) { chat.Messages.Clear(); } } }
public ChatID(ChatID chatID) : base(chatID.ID, chatID.NativePtr) { this.DialogID = chatID.DialogID; }