diff --git a/Blocks3D.vcproj b/Blocks3D.vcproj index 24c36f3..f8a502f 100644 --- a/Blocks3D.vcproj +++ b/Blocks3D.vcproj @@ -616,6 +616,14 @@ + + + + + + @@ -821,6 +833,14 @@ > + + + + #include "propertyGrid.h" #include "map" +#include "Properties/BoolProperty.h" class Instance { diff --git a/src/include/Properties/BoolProperty.h b/src/include/Properties/BoolProperty.h new file mode 100644 index 0000000..ebdfe51 --- /dev/null +++ b/src/include/Properties/BoolProperty.h @@ -0,0 +1,13 @@ +#pragma once +#include "Property.h" +#pragma once +class BoolProperty : public Property +{ +public: + template + BoolProperty(std::string name, bool& value) + { + Property(name, (T)value); + } + ~BoolProperty(void); +}; diff --git a/src/include/Properties/Property.h b/src/include/Properties/Property.h new file mode 100644 index 0000000..1519818 --- /dev/null +++ b/src/include/Properties/Property.h @@ -0,0 +1,19 @@ +#pragma once +#include "propertyGrid.h" +template +class Property +{ +public: + Property(std::string name, T& value) + { + value = t; + } + ~Property(void); + T getValue(); + void setValue(T); + PROPGRIDITEM getPropGridItem(); + void setProperty(LPPROPGRIDITEM item); +protected: + std::string name; + T* value; +}; diff --git a/src/source/Properties/Property.cpp b/src/source/Properties/Property.cpp new file mode 100644 index 0000000..e69de29