ReceiveDialog.cpp
上传用户:popouu88
上传日期:2013-02-11
资源大小:2894k
文件大小:1k
源码类别:

IP电话/视频会议

开发平台:

Visual C++

  1. // ReceiveDialog.cpp : implementation file
  2. //
  3. #include "stdafx.h"
  4. #include "file.h"
  5. #include "ReceiveDialog.h"
  6. #ifdef _DEBUG
  7. #define new DEBUG_NEW
  8. #undef THIS_FILE
  9. static char THIS_FILE[] = __FILE__;
  10. #endif
  11. /////////////////////////////////////////////////////////////////////////////
  12. // CReceiveDialog dialog
  13. CReceiveDialog::CReceiveDialog(PSendFileREQ * req , CWnd* pParent /*=NULL*/)
  14. : CDialog(CReceiveDialog::IDD, pParent)
  15. {
  16. //{{AFX_DATA_INIT(CReceiveDialog)
  17. //}}AFX_DATA_INIT
  18. this->sendREQ = req;
  19. }
  20. void CReceiveDialog::DoDataExchange(CDataExchange* pDX)
  21. {
  22. CDialog::DoDataExchange(pDX);
  23. //{{AFX_DATA_MAP(CReceiveDialog)
  24. DDX_Control(pDX, IDC_LIST, m_list);
  25. //}}AFX_DATA_MAP
  26. }
  27. BEGIN_MESSAGE_MAP(CReceiveDialog, CDialog)
  28. //{{AFX_MSG_MAP(CReceiveDialog)
  29. //}}AFX_MSG_MAP
  30. END_MESSAGE_MAP()
  31. /////////////////////////////////////////////////////////////////////////////
  32. // CReceiveDialog message handlers
  33. BOOL CReceiveDialog::OnInitDialog() 
  34. {
  35. CDialog::OnInitDialog( );
  36. this->SetWindowText( this->sendREQ->user_name + "  发送文件" );
  37. int i = 0 , j = 0;
  38. while( ( j = this->sendREQ->filename.Find( '|' , i ) ) != -1 )
  39. {
  40. this->m_list.AddString( this->sendREQ->filename.Mid( i , j - i ) );
  41. i = j + 1;
  42. }
  43. return true;
  44. }