#if wxUSE_EXTENDED_RTTI
-#include "wx/string.h"
-#include "wx/variant.h"
-
-class WXDLLIMPEXP_BASE wxObject;
-class WXDLLIMPEXP_BASE wxClassInfo;
-class WXDLLIMPEXP_BASE wxDynamicClassInfo;
-class WXDLLIMPEXP_BASE wxHashTable;
-class WXDLLIMPEXP_BASE wxHashTable_Node;
-class WXDLLIMPEXP_BASE wxObjectRefData;
-class WXDLLIMPEXP_BASE wxEvent;
-class WXDLLIMPEXP_BASE wxEvtHandler;
+#include "wx/xti.h"
// ----------------------------------------------------------------------------
// Constructor Bridges
{
public:
virtual ~wxObjectAllocatorAndCreator() { }
- virtual bool Create(wxObject * &o, wxVariantBase *args) = 0;
+ virtual bool Create(wxObject * &o, wxAny *args) = 0;
};
// a direct constructor bridge calls the operator new for this class and
class WXDLLIMPEXP_BASE wxObjectAllocator : public wxObjectAllocatorAndCreator
{
public:
- virtual bool Create(wxObject * &o, wxVariantBase *args) = 0;
+ virtual bool Create(wxObject * &o, wxAny *args) = 0;
};
template<typename Class>
struct wxObjectAllocatorAndCreator_0 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *)
+ bool Create(wxObject * &o, wxAny *)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create();
struct wxObjectAllocatorAndCreator_Dummy : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject *&, wxVariantBase *)
+ bool Create(wxObject *&, wxAny *)
{
return true;
}
template<typename Class>
struct wxDirectConstructorBridge_0 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class( );
return o != NULL;
template<typename Class, typename T0>
struct wxObjectAllocatorAndCreator_1 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0)
+ (args[0]).As(static_cast<T0*>(NULL))
);
}
};
template<typename Class, typename T0>
struct wxDirectConstructorBridge_1 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0)
+ (args[0]).As(static_cast<T0*>(NULL))
);
return o != NULL;
}
typename T0, typename T1>
struct wxObjectAllocatorAndCreator_2 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL))
);
}
};
typename T0, typename T1>
struct wxDirectConstructorBridge_2 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL))
);
return o != NULL;
}
typename T0, typename T1, typename T2>
struct wxObjectAllocatorAndCreator_3 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL))
);
}
};
typename T0, typename T1, typename T2>
struct wxDirectConstructorBridge_3 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL))
);
return o != NULL;
}
typename T0, typename T1, typename T2, typename T3>
struct wxObjectAllocatorAndCreator_4 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL))
);
}
};
typename T0, typename T1, typename T2, typename T3>
struct wxDirectConstructorBridge_4 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL))
);
return o != NULL;
}
typename T0, typename T1, typename T2, typename T3, typename T4>
struct wxObjectAllocatorAndCreator_5 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL))
);
}
};
typename T0, typename T1, typename T2, typename T3, typename T4>
struct wxDirectConstructorBridge_5 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL))
);
return o != NULL;
}
typename T0, typename T1, typename T2, typename T3, typename T4, typename T5>
struct wxObjectAllocatorAndCreator_6 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4),
- args[5].wxTEMPLATED_MEMBER_CALL(Get, T5)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL)),
+ (args[5]).As(static_cast<T5*>(NULL))
);
}
};
typename T0, typename T1, typename T2, typename T3, typename T4, typename T5>
struct wxDirectConstructorBridge_6 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4),
- args[5].wxTEMPLATED_MEMBER_CALL(Get, T5)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL)),
+ (args[5]).As(static_cast<T5*>(NULL))
);
return o != NULL;
}
typename T0, typename T1, typename T2, typename T3, typename T4, typename T5, typename T6>
struct wxObjectAllocatorAndCreator_7 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4),
- args[5].wxTEMPLATED_MEMBER_CALL(Get, T5),
- args[6].wxTEMPLATED_MEMBER_CALL(Get, T6)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL)),
+ (args[5]).As(static_cast<T5*>(NULL)),
+ (args[6]).As(static_cast<T6*>(NULL))
);
}
};
typename T0, typename T1, typename T2, typename T3, typename T4, typename T5, typename T6>
struct wxDirectConstructorBridge_7 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T5),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T6)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL)),
+ (args[5]).As(static_cast<T5*>(NULL)),
+ (args[6]).As(static_cast<T6*>(NULL))
);
return o != NULL;
}
typename T6, typename T7>
struct wxObjectAllocatorAndCreator_8 : public wxObjectAllocatorAndCreator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
Class *obj = wx_dynamic_cast(Class*, o);
return obj->Create(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4),
- args[5].wxTEMPLATED_MEMBER_CALL(Get, T5),
- args[6].wxTEMPLATED_MEMBER_CALL(Get, T6),
- args[7].wxTEMPLATED_MEMBER_CALL(Get, T7)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL)),
+ (args[5]).As(static_cast<T5*>(NULL)),
+ (args[6]).As(static_cast<T6*>(NULL)),
+ (args[7]).As(static_cast<T7*>(NULL))
);
}
};
typename T6, typename T7>
struct wxDirectConstructorBridge_8 : public wxObjectAllocator
{
- bool Create(wxObject * &o, wxVariantBase *args)
+ bool Create(wxObject * &o, wxAny *args)
{
o = new Class(
- args[0].wxTEMPLATED_MEMBER_CALL(Get, T0),
- args[1].wxTEMPLATED_MEMBER_CALL(Get, T1),
- args[2].wxTEMPLATED_MEMBER_CALL(Get, T2),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T3),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T4),
- args[3].wxTEMPLATED_MEMBER_CALL(Get, T5),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T6),
- args[4].wxTEMPLATED_MEMBER_CALL(Get, T7)
+ (args[0]).As(static_cast<T0*>(NULL)),
+ (args[1]).As(static_cast<T1*>(NULL)),
+ (args[2]).As(static_cast<T2*>(NULL)),
+ (args[3]).As(static_cast<T3*>(NULL)),
+ (args[4]).As(static_cast<T4*>(NULL)),
+ (args[5]).As(static_cast<T5*>(NULL)),
+ (args[6]).As(static_cast<T6*>(NULL)),
+ (args[7]).As(static_cast<T7*>(NULL))
);
return o != NULL;
}