X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/8253f2e0637d1c87e38e1b6163882bac35d15074..3b01b1fe4cb656f39290bf7f3891667855abe601:/src/generic/grid.cpp diff --git a/src/generic/grid.cpp b/src/generic/grid.cpp index b21a13d44b..9d0e0a9f69 100644 --- a/src/generic/grid.cpp +++ b/src/generic/grid.cpp @@ -206,7 +206,7 @@ public: wxGridRowLabelWindow *rowLblWin, wxGridColLabelWindow *colLblWin, wxWindowID id, const wxPoint &pos, const wxSize &size ); - ~wxGridWindow(); + ~wxGridWindow(){} void ScrollWindow( int dx, int dy, const wxRect *rect ); @@ -502,9 +502,11 @@ void wxGridCellEditor::Show(bool show, wxGridCellAttr *attr) m_colBgOld = m_control->GetBackgroundColour(); m_control->SetBackgroundColour(attr->GetBackgroundColour()); + // Workaround for GTK+1 font setting problem on some platforms +#if !defined(__WXGTK__) || defined(__WXGTK20__) m_fontOld = m_control->GetFont(); m_control->SetFont(attr->GetFont()); - +#endif // can't do anything more in the base class version, the other // attributes may only be used by the derived classes } @@ -523,12 +525,14 @@ void wxGridCellEditor::Show(bool show, wxGridCellAttr *attr) m_control->SetBackgroundColour(m_colBgOld); m_colBgOld = wxNullColour; } - + // Workaround for GTK+1 font setting problem on some platforms +#if !defined(__WXGTK__) || defined(__WXGTK20__) if ( m_fontOld.Ok() ) { m_control->SetFont(m_fontOld); m_fontOld = wxNullFont; } +#endif } } @@ -3700,11 +3704,6 @@ wxGridWindow::wxGridWindow( wxGrid *parent, } -wxGridWindow::~wxGridWindow() -{ -} - - void wxGridWindow::OnPaint( wxPaintEvent &WXUNUSED(event) ) { wxPaintDC dc( this ); @@ -9546,7 +9545,7 @@ void wxGrid::SetColSize( int col, int width ) void wxGrid::SetColMinimalWidth( int col, int width ) { if (width > GetColMinimalAcceptableWidth()) { - wxLongToLongHashMap::const_key_type key = (wxLongToLongHashMap::const_key_type)col; + wxLongToLongHashMap::key_type key = (wxLongToLongHashMap::key_type)col; m_colMinWidths[key] = width; } } @@ -9554,21 +9553,21 @@ void wxGrid::SetColMinimalWidth( int col, int width ) void wxGrid::SetRowMinimalHeight( int row, int width ) { if (width > GetRowMinimalAcceptableHeight()) { - wxLongToLongHashMap::const_key_type key = (wxLongToLongHashMap::const_key_type)row; + wxLongToLongHashMap::key_type key = (wxLongToLongHashMap::key_type)row; m_rowMinHeights[key] = width; } } int wxGrid::GetColMinimalWidth(int col) const { - wxLongToLongHashMap::const_key_type key = (wxLongToLongHashMap::const_key_type)col; + wxLongToLongHashMap::key_type key = (wxLongToLongHashMap::key_type)col; wxLongToLongHashMap::const_iterator it = m_colMinWidths.find(key); return it != m_colMinWidths.end() ? (int)it->second : m_minAcceptableColWidth; } int wxGrid::GetRowMinimalHeight(int row) const { - wxLongToLongHashMap::const_key_type key = (wxLongToLongHashMap::const_key_type)row; + wxLongToLongHashMap::key_type key = (wxLongToLongHashMap::key_type)row; wxLongToLongHashMap::const_iterator it = m_rowMinHeights.find(key); return it != m_rowMinHeights.end() ? (int)it->second : m_minAcceptableRowHeight; }