Eliminate -Wcast-qual warnings with GCC and Clang

Use const_cast, mutable, and various other changes to avoid -Wcast-qual
This commit is contained in:
Paul Cornett
2020-02-02 22:50:32 -08:00
parent 6724f8c052
commit 948ddc6e0f
115 changed files with 273 additions and 303 deletions

View File

@@ -27,7 +27,7 @@ class WXDLLIMPEXP_PROPGRID wxPGPropArgCls
public:
wxPGPropArgCls( const wxPGProperty* property )
{
m_ptr.property = (wxPGProperty*) property;
m_ptr.property = const_cast<wxPGProperty*>(property);
m_flags = IsProperty;
}
wxPGPropArgCls( const wxString& str )

View File

@@ -571,7 +571,7 @@ protected:
// Returns property by its label.
wxPGProperty* BaseGetPropertyByLabel( const wxString& label,
wxPGProperty* parent = NULL ) const;
const wxPGProperty* parent = NULL ) const;
// Unselect sub-properties.
void DoRemoveChildrenFromSelection(wxPGProperty* p, bool recursive,