On 5/24/06, Darwin Slattery <dar...@ho...> wrote:
> Thanks a million for your help and quick reply.
>
> I have started working on the .i files but I have come across something that
> I would like advice on.
>
> I have used the WX_DEFINE_OBJARRAY C++ macro in wxWidgets to create a
> wxArray class specific to wxURI's. I'm a bit confused as to how to represent
> this in a .i file e.g.
>
> #inculde <wx/uri.h>
> #include <wx/dynarray.h>
>
> WX_DECLARE_OBJARRAY(wxURI, wxURIArray);
>
> #include <wx/arrimpl.cpp>
>
> // wxWidgets container definition.
> WX_DEFINE_OBJARRAY(wxURIArray);
>
> class ...
> {
> wxURIArray getLinks();
> };
>
> I just want to know if I can declare a new class in the .i file called
> wxURIArray and add the wxArray member functions but replace the template
> type with the wxURI type?
That's exactly what you do, see bindings/wxwidgets/data.i and look for
wxArrayString and wxArrayInt. Just add the functions that are useful.
-John Labenski
|