X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/fe7b9ed6fdffb7dd72c9d7d4a1070e433189954f..9691c806e6fbb08b01c9eec9998ad1e8242c7df3:/include/wx/generic/grid.h diff --git a/include/wx/generic/grid.h b/include/wx/generic/grid.h index 7b929ad6b8..9c1f0083ee 100644 --- a/include/wx/generic/grid.h +++ b/include/wx/generic/grid.h @@ -583,9 +583,10 @@ public: }; // ctors - wxGridCellAttr() + wxGridCellAttr(wxGridCellAttr *attrDefault = NULL) { - Init(); + Init(attrDefault); + // MB: args used to be 0,0 here but wxALIGN_LEFT is 0 SetAlignment(-1, -1); } @@ -664,17 +665,7 @@ private: }; // the common part of all ctors - void Init() - { - m_nRef = 1; - - m_isReadOnly = Unset; - - m_renderer = NULL; - m_editor = NULL; - - m_attrkind = wxGridCellAttr::Cell; - } + void Init(wxGridCellAttr *attrDefault = NULL); // the dtor is private because only DecRef() can delete us ~wxGridCellAttr() @@ -1414,6 +1405,8 @@ public: { m_extraWidth = extraWidth; m_extraHeight = extraHeight; + + CalcDimensions(); } // Accessors for component windows