diff --git a/include/wx/generic/grid.h b/include/wx/generic/grid.h index 32a634158a..c1adbb0b24 100644 --- a/include/wx/generic/grid.h +++ b/include/wx/generic/grid.h @@ -789,9 +789,12 @@ private: // enum wxGridTableRequest { + // The first two requests never did anything, simply don't use them. +#if WXWIN_COMPATIBILITY_3_0 wxGRIDTABLE_REQUEST_VIEW_GET_VALUES = 2000, wxGRIDTABLE_REQUEST_VIEW_SEND_VALUES, - wxGRIDTABLE_NOTIFY_ROWS_INSERTED, +#endif // WXWIN_COMPATIBILITY_3_0 + wxGRIDTABLE_NOTIFY_ROWS_INSERTED = 2002, wxGRIDTABLE_NOTIFY_ROWS_APPENDED, wxGRIDTABLE_NOTIFY_ROWS_DELETED, wxGRIDTABLE_NOTIFY_COLS_INSERTED, @@ -2164,11 +2167,6 @@ protected: { UpdateBlockBeingSelected(topLeft.GetRow(), topLeft.GetCol(), bottomRight.GetRow(), bottomRight.GetCol()); } - // ------ functions to get/send data (see also public functions) - // - bool GetModelValues(); - bool SetModelValues(); - friend class WXDLLIMPEXP_FWD_ADV wxGridSelection; friend class wxGridRowOperations; friend class wxGridColumnOperations; diff --git a/src/generic/grid.cpp b/src/generic/grid.cpp index ca1be3c23e..921780caf3 100644 --- a/src/generic/grid.cpp +++ b/src/generic/grid.cpp @@ -4538,12 +4538,6 @@ bool wxGrid::ProcessTableMessage( wxGridTableMessage& msg ) { switch ( msg.GetId() ) { - case wxGRIDTABLE_REQUEST_VIEW_GET_VALUES: - return GetModelValues(); - - case wxGRIDTABLE_REQUEST_VIEW_SEND_VALUES: - return SetModelValues(); - case wxGRIDTABLE_NOTIFY_ROWS_INSERTED: case wxGRIDTABLE_NOTIFY_ROWS_APPENDED: case wxGRIDTABLE_NOTIFY_ROWS_DELETED: @@ -5308,51 +5302,6 @@ wxGrid::UpdateBlockBeingSelected(int topRow, int leftCol, m_selectedBlockBottomRight = updateBottomRight; } -// -// ------ functions to get/send data (see also public functions) -// - -bool wxGrid::GetModelValues() -{ - // Hide the editor, so it won't hide a changed value. - HideCellEditControl(); - - if ( m_table ) - { - // all we need to do is repaint the grid - // - m_gridWin->Refresh(); - return true; - } - - return false; -} - -bool wxGrid::SetModelValues() -{ - int row, col; - - // Disable the editor, so it won't hide a changed value. - // Do we also want to save the current value of the editor first? - // I think so ... - DisableCellEditControl(); - - if ( m_table ) - { - for ( row = 0; row < m_numRows; row++ ) - { - for ( col = 0; col < m_numCols; col++ ) - { - m_table->SetValue( row, col, GetCellValue(row, col) ); - } - } - - return true; - } - - return false; -} - // Note - this function only draws cells that are in the list of // exposed cells (usually set from the update region by // CalcExposedCells)