コード例 #1
0
        private void ParseInviteMsg(string[] _msg)
        {
            chatKey = ChatUtils.GetFormKey(_msg[1], ConfigHelper.Id);

            string[] addedIdArray = _msg[2].Split('/');

            foreach (string addedId in addedIdArray)
            {
                memberList.Add(Members.GetByUserId(addedId));
            }
        }
コード例 #2
0
        private void ParseChatMsg(string[] _msg)
        {
            chatKey = ChatUtils.GetFormKey(_msg[1], ConfigHelper.Id);

            string[] addedIdArray = _msg[2].Split('/');

            foreach (string addedId in addedIdArray)
            {
                memberList.Add(Members.GetByUserId(addedId));
            }

            userId   = addedIdArray[0];
            userName = _msg[3];
            msg      = Utils.DecodeMsg(_msg[4]);
        }
コード例 #3
0
ファイル: ChatForm.cs プロジェクト: WeDoCrm/WeDoMessenger2.0
 public ChatForm(MsgrConnection connection, MiscController miscCtrl, MemberObj chatterObj)
 {
     try
     {
         InitializeComponent();
         this.connection = connection;
         this.miscCtrl   = miscCtrl;
         formKey         = ChatUtils.GetFormKey(chatterObj.Id, ConfigHelper.Id);
         Initialize();
         Logger.info(string.Format("채팅창생성 key[{0}]", formKey));
         SetChatterOnFormOpening(chatterObj);//대화창에 참가자 노드 추가(key=id, text=name)
     }
     catch (Exception ex)
     {
         Logger.error(ex.ToString());
         MessageBox.Show("화면 초기화중 오류가 발생했습니다.\n 담당자에게 문의하세요.", "초기화 오류", MessageBoxButtons.OK, MessageBoxIcon.Error);
     }
 }
コード例 #4
0
ファイル: ChatForm.cs プロジェクト: WeDoCrm/WeDoMessenger2.0
        /// <param name="chatterList">채팅가능자 조합한 키값(myid/id/id/id..)</param>
        public ChatForm(MsgrConnection connection, MiscController miscCtrl, List <MemberObj> groupList)
        {
            try
            {
                InitializeComponent();
                this.connection = connection;
                this.miscCtrl   = miscCtrl;
                List <string> userList = new List <string>();
                foreach (MemberObj userObj in groupList)
                {
                    if (userObj.Status != MsgrUserStatus.LOGOUT)
                    {
                        userList.Add(userObj.Id);
                    }
                }
                formKey = ChatUtils.GetFormKey(userList, ConfigHelper.Id);
                Initialize();
                Logger.info(string.Format("채팅창생성 key[{0}]", formKey));

                foreach (MemberObj userObj in groupList)
                {
                    if (userObj.Status != MsgrUserStatus.LOGOUT)
                    {
                        SetChatterOnFormOpening(userObj);
                    }
                    else
                    {
                        PostCanNotJoinMessage(userObj.Name);
                    }
                }
            }
            catch (Exception ex)
            {
                Logger.error(ex.ToString());
                MessageBox.Show("화면 초기화중 오류가 발생했습니다.\n 담당자에게 문의하세요.", "초기화 오류", MessageBoxButtons.OK, MessageBoxIcon.Error);
            }
        }
コード例 #5
0
 private void ParseChatterQuitMsg(string[] _msg)
 {
     chatKey = ChatUtils.GetFormKey(_msg[1], ConfigHelper.Id);
     quitter = Members.GetByUserId(_msg[2]);
 }