Browse Source

Fix bug which would throw away all enum values after a Get().

(It was allocating a stack variable copy of the singleton, which
when freed cleared the singleton's m_choices.)

https://forum.kicad.info/t/need-some-guinea-pigs-for-a-rule-based-drc-prototype/22955/85
pull/16/head
Jeff Young 5 years ago
parent
commit
ac6ceb84bf
  1. 2
      include/property.h

2
include/property.h

@ -583,7 +583,7 @@ private:
wxAnyValueType* dstType, wxAnyValueBuffer& dst ) const override\
{\
type value = GetValue(src);\
ENUM_MAP<type> conv = ENUM_MAP<type>::Instance();\
ENUM_MAP<type>& conv = ENUM_MAP<type>::Instance();\
if( dstType->CheckType<wxString>() )\
{\
wxAnyValueTypeImpl<wxString>::SetValue( conv.ToString( value ), dst );\

Loading…
Cancel
Save