示例#1
0
 /// <remarks/>
 public void TransferChatAsync(ChatRequest chatRequest) {
     this.TransferChatAsync(chatRequest, null);
 }
示例#2
0
 /// <remarks/>
 public void TransferChatAsync(ChatRequest chatRequest, object userState) {
     if ((this.TransferChatOperationCompleted == null)) {
         this.TransferChatOperationCompleted = new System.Threading.SendOrPostCallback(this.OnTransferChatOperationCompleted);
     }
     this.InvokeAsync("TransferChat", new object[] {
                 chatRequest}, this.TransferChatOperationCompleted, userState);
 }
示例#3
0
 public void TransferChat(ChatRequest chatRequest) {
     this.Invoke("TransferChat", new object[] {
                 chatRequest});
 }
示例#4
0
 /// <remarks/>
 public void RemoveChatRequestAsync(System.Guid key, ChatRequest req, object userState) {
     if ((this.RemoveChatRequestOperationCompleted == null)) {
         this.RemoveChatRequestOperationCompleted = new System.Threading.SendOrPostCallback(this.OnRemoveChatRequestOperationCompleted);
     }
     this.InvokeAsync("RemoveChatRequest", new object[] {
                 key,
                 req}, this.RemoveChatRequestOperationCompleted, userState);
 }
示例#5
0
 /// <remarks/>
 public void RemoveChatRequestAsync(System.Guid key, ChatRequest req) {
     this.RemoveChatRequestAsync(key, req, null);
 }
示例#6
0
 public void RemoveChatRequest(System.Guid key, ChatRequest req) {
     this.Invoke("RemoveChatRequest", new object[] {
                 key,
                 req});
 }
示例#7
0
        private void btnTransfer_Click(object sender, EventArgs e)
        {
            if (MessageBox.Show("Are you sure you want to transfer the chat session?", "Transfering chat", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes)
            {
                ChatRequest newReq = new ChatRequest();
                newReq.OperatorId = Program.CurrentOperator.OperatorId;

                if (chkWarnVisitor.Checked)
                {
                    ChatMessage msg = new ChatMessage();
                    msg.ChatId = ChatId;
                    msg.Message = "Your chat session has been transfered to : " + cboOperators.Text;
                    msg.Name = "System";
                    //msg.SentDate = DateTime.Now.ToUniversalTime().Ticks;

                    ws.AddMessage(new Guid(Program.CurrentOperator.Password), msg);
                }

                ((ControlPanel)this.ParentForm).EndChat(null, ChatId);

                ws.TransferChat(newReq);
            }
        }