home *** CD-ROM | disk | FTP | other *** search
/ Xentax forum attachments archive / xentax.7z / 8090 / ModelEdit.7z / MyEdit.cpp < prev    next >
Encoding:
C/C++ Source or Header  |  2006-03-08  |  827 b   |  46 lines

  1. // MyEdit.cpp : implementation file
  2. //
  3.  
  4. #include "precompile.h"
  5. #include "modeledit.h"
  6. #include "myedit.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. // CMyEdit
  16.  
  17. CMyEdit::CMyEdit()
  18. {
  19. }
  20.  
  21.  
  22. CMyEdit::~CMyEdit()
  23. {
  24. }
  25.  
  26.  
  27. BEGIN_MESSAGE_MAP(CMyEdit, CEdit)
  28.     //{{AFX_MSG_MAP(CMyEdit)
  29.     ON_WM_KEYDOWN()
  30.     //}}AFX_MSG_MAP
  31. END_MESSAGE_MAP()
  32.  
  33. /////////////////////////////////////////////////////////////////////////////
  34. // CMyEdit message handlers
  35.  
  36. void CMyEdit::OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags) 
  37. {
  38.     if( nChar == VK_RETURN )
  39.     {
  40.         GetParent( )->SendMessage( WM_EDITAPPLY, WPARAM( m_hWnd ));
  41.         return;
  42.     }
  43.  
  44.     CEdit::OnKeyDown(nChar, nRepCnt, nFlags);
  45. }
  46.