Use dedicated function to get common value label in wxPropertyGrid
This commit is contained in:
parent
6d9e362b1f
commit
dec03c5d89
2 changed files with 2 additions and 3 deletions
|
|
@ -1136,7 +1136,7 @@ public:
|
|||
wxString GetCommonValueLabel( unsigned int i ) const
|
||||
{
|
||||
wxCHECK_MSG( i < m_commonValues.size(), wxString(), "Invalid item index" );
|
||||
return GetCommonValue(i)->GetLabel();
|
||||
return m_commonValues[i]->GetLabel();
|
||||
}
|
||||
|
||||
// Returns index of common value that will truly change value to
|
||||
|
|
|
|||
|
|
@ -716,8 +716,7 @@ void wxPropertyGrid::OnComboItemPaint( const wxPGComboBox* pCb,
|
|||
comValIndex = item - choiceCount;
|
||||
if ( !p->IsValueUnspecified() || !(flags & wxODCB_PAINTING_CONTROL) )
|
||||
{
|
||||
const wxPGCommonValue* cv = GetCommonValue(comValIndex);
|
||||
text = cv->GetLabel();
|
||||
text = GetCommonValueLabel(comValIndex);
|
||||
}
|
||||
}
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue