예제 #1
0
파일: NSConvList.cs 프로젝트: zvrr/mars-1
        protected override void onFinished(ConversationListRequest request, ConversationListResponse response)
        {
            MarsEventArgs args = new MarsEventArgs();

            if (response == null)
            {
                args.Code = EventConst.FAIL;
            }
            else
            {
                args.Code = EventConst.SUCCESS;
                ObservableCollection <LocalConversation> resultList = new ObservableCollection <LocalConversation>();
                if (response.ListList != null)
                {
                    foreach (Conversation con in response.ListList)
                    {
                        LocalConversation localCon = new LocalConversation();
                        localCon.ConId     = con.Topic;
                        localCon.ConName   = con.Name;
                        localCon.ConNotice = con.Notice;
                        resultList.Add(localCon);
                    }
                }
                args.Data = resultList;
            }
            MarsPushMgr.onPush(getCmdID(), args);
        }
예제 #2
0
파일: NSConvList.cs 프로젝트: zvrr/mars-1
        protected override void onFailed(ConversationListRequest request, ConversationListResponse response)
        {
            MarsEventArgs args = new MarsEventArgs();

            args.Code = EventConst.FAIL;
            MarsPushMgr.onPush(getCmdID(), args);
        }