home *** CD-ROM | disk | FTP | other *** search
/ Mastering Visual Basic 5 / MasteringVisualBasic5.iso / protview / demowinx / data.2 / marquee / samples / MFC / TICKER / TKNEXT.CPP < prev    next >
Encoding:
C/C++ Source or Header  |  1996-07-11  |  1014 b   |  51 lines

  1. // TkNext.cpp : implementation file
  2. //
  3.  
  4. #include "stdafx.h"
  5. #include "ticker.h"
  6. #include "TkNext.h"
  7.  
  8. #ifdef _DEBUG
  9. #define new DEBUG_NEW
  10. #undef THIS_FILE
  11. static char THIS_FILE[] = __FILE__;
  12. #endif
  13.  
  14. /////////////////////////////////////////////////////////////////////////////
  15. // TkNext dialog
  16.  
  17.  
  18. TkNext::TkNext(CWnd* pParent /*=NULL*/)
  19.     : CDialog(TkNext::IDD, pParent)
  20. {
  21.     //{{AFX_DATA_INIT(TkNext)
  22.     m_text = _T("");
  23.     //}}AFX_DATA_INIT
  24. }
  25.  
  26.  
  27. void TkNext::DoDataExchange(CDataExchange* pDX)
  28. {
  29.     CDialog::DoDataExchange(pDX);
  30.     //{{AFX_DATA_MAP(TkNext)
  31.     DDX_Text(pDX, IDC_TEXT, m_text);
  32.     DDX_Control(pDX, IDC_TICKERCTRL1, m_tk);
  33.     //}}AFX_DATA_MAP
  34. }
  35.  
  36.  
  37. BEGIN_MESSAGE_MAP(TkNext, CDialog)
  38.     //{{AFX_MSG_MAP(TkNext)
  39.     ON_BN_CLICKED(IDC_NEXT, OnNext)
  40.     //}}AFX_MSG_MAP
  41. END_MESSAGE_MAP()
  42.  
  43. /////////////////////////////////////////////////////////////////////////////
  44. // TkNext message handlers
  45.  
  46. void TkNext::OnNext() 
  47. {
  48.    UpdateData(TRUE);
  49.    m_tk.SetNextDisplayString(m_text);
  50. }
  51.