Implement wxNumericProperty as a base class for all wxPG numeric properties
All numeric properties (wxIntProperty, wxUIntProperty, wxFloatProperty) share some features (like specific attributes, numeric validation, SpinCtrl editor support) so for the sake of clear design it would be good to derive them from the common base class (wxNumericProperty) in which all shared functions are implemented. This class is not intended to be instantiated so it's an abstract class.
This commit is contained in:
@@ -1191,7 +1191,7 @@ void FormMain::PopulateWithExamples ()
|
||||
pg->Append( new wxIntProperty ( "SpinCtrl", wxPG_LABEL, 0L ) );
|
||||
|
||||
pg->SetPropertyEditor( "SpinCtrl", wxPGEditor_SpinCtrl );
|
||||
pg->SetPropertyAttribute( "SpinCtrl", wxPG_ATTR_MIN, -10L ); // Use constants instead of string
|
||||
pg->SetPropertyAttribute( "SpinCtrl", wxPG_ATTR_MIN, -2L ); // Use constants instead of string
|
||||
pg->SetPropertyAttribute( "SpinCtrl", wxPG_ATTR_MAX, 16384L ); // for reduced binary size.
|
||||
pg->SetPropertyAttribute( "SpinCtrl", wxPG_ATTR_SPINCTRL_STEP, 2L );
|
||||
pg->SetPropertyAttribute( "SpinCtrl", wxPG_ATTR_SPINCTRL_MOTION, true );
|
||||
|
Reference in New Issue
Block a user