public void AddReceiveHttpFile(CooperationFileDownloadResponse response)
        {
            this.ShowFileList();
            NewFileListItem item = new NewFileListItem(response.fileName, response.file_Id, response.fileSize, this, this.staff, response.iconString);

            this.FileList.fileList.Items.Add(item);
            item.EndEvent = new NewFileListItem.EndEventDelegate(this.FileEndEventHandle);
        }
 public void AddReceiveHttpFile(CooperationFileDownloadResponse response)
 {
     this.ShowFileList();
     NewFileListItem item = new NewFileListItem(response.fileName, response.file_Id, response.fileSize, this, this.staff, response.iconString);
     this.FileList.fileList.Items.Add(item);
     item.EndEvent = new NewFileListItem.EndEventDelegate(this.FileEndEventHandle);
 }
Пример #3
0
 private void CooperationStaffFileDownloadEvent(CooperationFileDownloadResponse response)
 {
     try
     {
         INWindow inWindow = this.dataService.INWindow as INWindow;
         if (response != null && inWindow != null)
         {
             CoopStaffTab item = this.dataService.GetCooperationStaffChatTab(response.fromUid, response.projectId) as CoopStaffTab;
             if (item == null)
             {
                 CooperationStaff staff = this.dataService.GetCooperationStaff(response.fromUid, response.projectId);
                 CooperationProjectWrapper cooperationProjectWrapper = this.dataService.GetCooperationProjectWrapper(response.projectId);
                 if (staff != null && cooperationProjectWrapper != null)
                 {
                     item = new CoopStaffTab(staff, cooperationProjectWrapper);
                     item.SetFlashingStyle();
                     ((INWindow)this.dataService.INWindow).ContentTab.Items.Add(item);
                     this.dataService.AddCooperationStaffChatTab(staff.Uid, staff.UnitedProjectid, item);
                 }
             }
             if (item != null)
             {
                 CoopStaffChatTabControl tab = item.TabContent;
                 if (tab != null)
                 {
                     tab.AddReceiveHttpFile(response);
                     if (!this.IsCurrentItem(item))
                     {
                         item.SetFlashingStyle();
                     }
                 }
             }
             this.PickUpMessageProcessor();
             MessageBoxWindow mbw = this.dataModel.GetMessageBox();
             if (mbw != null)
             {
                 mbw.Refresh();
             }
             if (inWindow.WindowState == WindowState.Minimized && item != null)
             {
                 this.ActiveInWindow();
                 this.SelectedTab(item);
             }
             else
             {
                 this.ActiveInWindow();
             }
             this.FlashIconPorcessor();
         }
     }
     catch (System.Exception)
     {
     }
 }