Pass argument of proper type to wxPropertyGridInterface::SetPropertyBackgroundColour
The last argument passed to this function should be an int flag not a Boolean value. Boolean value 'true' passed here is converted to int 1 so wxPG_RECURSE flag is never set and the background colour is never changed for sub-properties. Closes #18333.
This commit is contained in:
@@ -2575,8 +2575,8 @@ FormMain::OnSetBackgroundColour( wxCommandEvent& event )
|
||||
|
||||
if ( col.IsOk() )
|
||||
{
|
||||
bool recursively = (event.GetId()==ID_SETBGCOLOURRECUR) ? true : false;
|
||||
pg->SetPropertyBackgroundColour(prop, col, recursively);
|
||||
int flags = (event.GetId()==ID_SETBGCOLOURRECUR) ? wxPG_RECURSE : 0;
|
||||
pg->SetPropertyBackgroundColour(prop, col, flags);
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user