From: Stefan Csomor Date: Fri, 29 Aug 2003 19:07:58 +0000 (+0000) Subject: added WX_IMPLEMENT_PROPERTY X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/584e60740634657e2218b9486f8abd752e2d9ad1?ds=sidebyside added WX_IMPLEMENT_PROPERTY git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23297 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/include/wx/xti.h b/include/wx/xti.h index 166502080a..db55674802 100644 --- a/include/wx/xti.h +++ b/include/wx/xti.h @@ -1140,6 +1140,17 @@ WX_DECLARE_STRING_HASH_MAP_WITH_DECL( wxPropertyInfo* , wxPropertyInfoMap , clas static wxDelegateTypeInfo _typeInfo##name( eventType , lastEventType , CLASSINFO( eventClass ) ) ; \ static wxPropertyInfo _propertyInfo##name( first , class_t::GetClassInfoStatic() , wxT(#name) , &_typeInfo##name , NULL , wxxVariant() ) ; \ +// ---------------------------------------------------------------------------- +// Implementation Helper for Simple Properties +// ---------------------------------------------------------------------------- + +#define WX_IMPLEMENT_PROPERTY(name, type) \ +private:\ + type m_##name; \ +public: \ + void Set##name( type const & p) { m_##name = p; } \ + type const & Get##name() const { return m_##name; } + // ---------------------------------------------------------------------------- // Handler Info //