home *** CD-ROM | disk | FTP | other *** search
/ QBasic & Borland Pascal & C / Delphi5.iso / C / BC_502 / CHATTER.PAK / CHATSOCK.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1997-05-06  |  902 b   |  39 lines

  1. // chatsock.cpp : implementation file
  2. //
  3. // This is a part of the Microsoft Foundation Classes C++ library.
  4. // Copyright (C) 1992-1995 Microsoft Corporation
  5. // All rights reserved.
  6. //
  7. // This source code is only intended as a supplement to the
  8. // Microsoft Foundation Classes Reference and related
  9. // electronic documentation provided with the library.
  10. // See these sources for detailed information regarding the
  11. // Microsoft Foundation Classes product.
  12.  
  13. #include "stdafx.h"
  14. #include "chatter.h"
  15.  
  16. #include "chatsock.h"
  17. #include "chatdoc.h"
  18.  
  19. #include <stddef.h>
  20.  
  21. #ifdef _DEBUG
  22. #undef THIS_FILE
  23. static char BASED_CODE THIS_FILE[] = __FILE__;
  24. #endif
  25.  
  26. IMPLEMENT_DYNAMIC(CChatSocket, CSocket)
  27.  
  28. CChatSocket::CChatSocket(CChatDoc* pDoc)
  29. {
  30.     m_pDoc = pDoc;
  31. }
  32.  
  33. void CChatSocket::OnReceive(int nErrorCode)
  34. {
  35.     CSocket::OnReceive(nErrorCode);
  36.  
  37.     m_pDoc->ProcessPendingRead();
  38. }
  39.