00001
00002
00003
00004
00006
00007 #include "stdafx.h"
00008 #include "GridCellNumeric.h"
00009 #include "../GridCtrl_src/inplaceedit.h"
00010 #include "../GridCtrl_src/GridCtrl.h"
00011
00012 IMPLEMENT_DYNCREATE(CGridCellNumeric, CGridCell)
00013
00014 #ifdef _DEBUG
00015 #undef THIS_FILE
00016 static char THIS_FILE[]=__FILE__;
00017 #define new DEBUG_NEW
00018 #endif
00019
00021
00023
00024
00025 BOOL CGridCellNumeric::Edit(int nRow, int nCol, CRect rect, CPoint , UINT nID, UINT nChar)
00026 {
00027 m_bEditing = TRUE;
00028
00029
00030 m_pEditWnd = new CInPlaceEdit(GetGrid(), rect, ES_NUMBER, nID, nRow, nCol,
00031 GetText(), nChar);
00032
00033 return TRUE;
00034 }
00035
00036
00037 void CGridCellNumeric::EndEdit()
00038 {
00039 if (m_pEditWnd)
00040 ((CInPlaceEdit*)m_pEditWnd)->EndEdit();
00041 }
00042