X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/90e572f1e5af1e51fd14e2e1e6f64fa3e258e590..9a7b7798282622e445efc3318b6c85ff0bed9af8:/src/generic/gridctrl.cpp?ds=sidebyside diff --git a/src/generic/gridctrl.cpp b/src/generic/gridctrl.cpp index 124606e4ac..e8da62f564 100644 --- a/src/generic/gridctrl.cpp +++ b/src/generic/gridctrl.cpp @@ -17,12 +17,14 @@ #if wxUSE_GRID +#include "wx/generic/gridctrl.h" + #ifndef WX_PRECOMP #include "wx/textctrl.h" #include "wx/dc.h" + #include "wx/combobox.h" #endif // WX_PRECOMP -#include "wx/generic/gridctrl.h" #include "wx/tokenzr.h" // ---------------------------------------------------------------------------- @@ -74,7 +76,7 @@ wxString wxGridCellDateTimeRenderer::GetString(const wxGrid& grid, int row, int if (!hasDatetime ) { text = table->GetValue(row, col); - hasDatetime = (val.ParseFormat( text, m_iformat, m_dateDef ) != (wxChar *)NULL) ; + hasDatetime = (val.ParseFormat(text.c_str(), m_iformat, m_dateDef) != (wxChar *)NULL) ; } if ( hasDatetime ) @@ -290,12 +292,8 @@ wxGridCellAutoWrapStringEditor::Create(wxWindow* parent, wxWindowID id, wxEvtHandler* evtHandler) { - m_control = new wxTextCtrl(parent, id, wxEmptyString, - wxDefaultPosition, wxDefaultSize, - wxTE_MULTILINE | wxTE_RICH); - - - wxGridCellEditor::Create(parent, id, evtHandler); + wxGridCellTextEditor::DoCreate(parent, id, evtHandler, + wxTE_MULTILINE | wxTE_RICH); } void