Ensure that wxGrid appearance always reflects its enabled state
Override DoEnable() in wxGrid instead of Enable() to ensure that the grid is shown appropriately for its current state whenever either it or its parent is disabled. Note that this also fixes the bug with only the main grid window being refreshed, but not the row/column headers, which also need to be.
This commit is contained in:
@@ -1947,7 +1947,6 @@ public:
|
||||
|
||||
|
||||
// override some base class functions
|
||||
virtual bool Enable(bool enable = true) wxOVERRIDE;
|
||||
virtual wxWindow *GetMainWindowOfCompositeControl() wxOVERRIDE
|
||||
{ return (wxWindow*)m_gridWin; }
|
||||
virtual void Fit() wxOVERRIDE;
|
||||
@@ -1957,6 +1956,7 @@ public:
|
||||
|
||||
protected:
|
||||
virtual wxSize DoGetBestSize() const wxOVERRIDE;
|
||||
virtual void DoEnable(bool enable) wxOVERRIDE;
|
||||
|
||||
bool m_created;
|
||||
|
||||
|
Reference in New Issue
Block a user