]> git.saurik.com Git - wxWidgets.git/blame - wxPython/contrib/xrc/xrc.cpp
Added generic LoadObject methods that can load any classtype from a
[wxWidgets.git] / wxPython / contrib / xrc / xrc.cpp
CommitLineData
d56cebe7
RD
1/*
2 * FILE : contrib/xrc/xrc.cpp
3 *
4 * This file was automatically generated by :
5 * Simplified Wrapper and Interface Generator (SWIG)
6 * Version 1.1 (Build 883)
7 *
8 * Portions Copyright (c) 1995-1998
9 * The University of Utah and The Regents of the University of California.
10 * Permission is granted to distribute this file in any manner provided
11 * this notice remains intact.
12 *
13 * Do not make changes to this file--changes will be lost!
14 *
15 */
16
17
18#define SWIGCODE
19/* Implementation : PYTHON */
20
21#define SWIGPYTHON
22#include <string.h>
23#include <stdlib.h>
24/* Definitions for Windows/Unix exporting */
25#if defined(__WIN32__)
26# if defined(_MSC_VER)
27# define SWIGEXPORT(a) __declspec(dllexport) a
28# else
29# if defined(__BORLANDC__)
30# define SWIGEXPORT(a) a _export
31# else
32# define SWIGEXPORT(a) a
33# endif
34# endif
35#else
36# define SWIGEXPORT(a) a
37#endif
38
39#include "Python.h"
40
41#ifdef __cplusplus
42extern "C" {
43#endif
44
45extern void SWIG_MakePtr(char *, void *, char *);
46extern void SWIG_RegisterMapping(char *, char *, void *(*)(void *));
47extern char *SWIG_GetPtr(char *, void **, char *);
48extern char *SWIG_GetPtrObj(PyObject *, void **, char *);
49extern void SWIG_addvarlink(PyObject *, char *, PyObject *(*)(void), int (*)(PyObject *));
50extern PyObject *SWIG_newvarlink(void);
51#ifdef __cplusplus
52}
53#endif
54#define SWIG_init initxrcc
55
56#define SWIG_name "xrcc"
57
6e2129f9 58#include "wxPython.h"
d56cebe7 59#include "wx/xrc/xmlres.h"
cd834e7b
RD
60#include <wx/filesys.h>
61#include <wx/fs_mem.h>
d56cebe7
RD
62
63
64static PyObject* t_output_helper(PyObject* target, PyObject* o) {
65 PyObject* o2;
66 PyObject* o3;
67
68 if (!target) {
69 target = o;
70 } else if (target == Py_None) {
71 Py_DECREF(Py_None);
72 target = o;
73 } else {
74 if (!PyTuple_Check(target)) {
75 o2 = target;
76 target = PyTuple_New(1);
77 PyTuple_SetItem(target, 0, o2);
78 }
79 o3 = PyTuple_New(1);
80 PyTuple_SetItem(o3, 0, o);
81
82 o2 = target;
83 target = PySequence_Concat(o2, o3);
84 Py_DECREF(o2);
85 Py_DECREF(o3);
86 }
87 return target;
88}
d56cebe7
RD
89#ifdef __cplusplus
90extern "C" {
91#endif
d56cebe7
RD
92static void *SwigwxXmlResourceTowxObject(void *ptr) {
93 wxXmlResource *src;
94 wxObject *dest;
95 src = (wxXmlResource *) ptr;
96 dest = (wxObject *) src;
97 return (void *) dest;
98}
99
cd834e7b
RD
100#define new_wxXmlResource(_swigarg0,_swigarg1) (new wxXmlResource(_swigarg0,_swigarg1))
101static PyObject *_wrap_new_wxXmlResource(PyObject *self, PyObject *args, PyObject *kwargs) {
d56cebe7
RD
102 PyObject * _resultobj;
103 wxXmlResource * _result;
cd834e7b
RD
104 wxString * _arg0;
105 int _arg1 = (int ) (wxXRC_USE_LOCALE);
106 PyObject * _obj0 = 0;
107 char *_kwnames[] = { "filemask","flags", NULL };
d56cebe7
RD
108 char _ptemp[128];
109
110 self = self;
cd834e7b
RD
111 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O|i:new_wxXmlResource",_kwnames,&_obj0,&_arg1))
112 return NULL;
113{
114 _arg0 = wxString_in_helper(_obj0);
115 if (_arg0 == NULL)
d56cebe7 116 return NULL;
cd834e7b 117}
d56cebe7 118{
4268f798 119 PyThreadState* __tstate = wxPyBeginAllowThreads();
cd834e7b 120 _result = (wxXmlResource *)new_wxXmlResource(*_arg0,_arg1);
d56cebe7 121
4268f798
RD
122 wxPyEndAllowThreads(__tstate);
123 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
124} if (_result) {
125 SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p");
126 _resultobj = Py_BuildValue("s",_ptemp);
127 } else {
128 Py_INCREF(Py_None);
129 _resultobj = Py_None;
130 }
cd834e7b
RD
131{
132 if (_obj0)
133 delete _arg0;
134}
d56cebe7
RD
135 return _resultobj;
136}
137
cd834e7b
RD
138#define new_wxEmptyXmlResource(_swigarg0) (new wxXmlResource(_swigarg0))
139static PyObject *_wrap_new_wxEmptyXmlResource(PyObject *self, PyObject *args, PyObject *kwargs) {
d56cebe7
RD
140 PyObject * _resultobj;
141 wxXmlResource * _result;
cd834e7b
RD
142 int _arg0 = (int ) (wxXRC_USE_LOCALE);
143 char *_kwnames[] = { "flags", NULL };
d56cebe7
RD
144 char _ptemp[128];
145
146 self = self;
cd834e7b 147 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"|i:new_wxEmptyXmlResource",_kwnames,&_arg0))
d56cebe7 148 return NULL;
d56cebe7 149{
4268f798 150 PyThreadState* __tstate = wxPyBeginAllowThreads();
cd834e7b 151 _result = (wxXmlResource *)new_wxEmptyXmlResource(_arg0);
d56cebe7 152
4268f798
RD
153 wxPyEndAllowThreads(__tstate);
154 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
155} if (_result) {
156 SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p");
157 _resultobj = Py_BuildValue("s",_ptemp);
158 } else {
159 Py_INCREF(Py_None);
160 _resultobj = Py_None;
161 }
d56cebe7
RD
162 return _resultobj;
163}
164
165#define delete_wxXmlResource(_swigobj) (delete _swigobj)
166static PyObject *_wrap_delete_wxXmlResource(PyObject *self, PyObject *args, PyObject *kwargs) {
167 PyObject * _resultobj;
168 wxXmlResource * _arg0;
169 PyObject * _argo0 = 0;
170 char *_kwnames[] = { "self", NULL };
171
172 self = self;
173 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:delete_wxXmlResource",_kwnames,&_argo0))
174 return NULL;
175 if (_argo0) {
176 if (_argo0 == Py_None) { _arg0 = NULL; }
177 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
178 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of delete_wxXmlResource. Expected _wxXmlResource_p.");
179 return NULL;
180 }
181 }
182{
4268f798 183 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 184 delete_wxXmlResource(_arg0);
d56cebe7 185
4268f798
RD
186 wxPyEndAllowThreads(__tstate);
187 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
188} Py_INCREF(Py_None);
189 _resultobj = Py_None;
190 return _resultobj;
191}
192
193#define wxXmlResource_Load(_swigobj,_swigarg0) (_swigobj->Load(_swigarg0))
194static PyObject *_wrap_wxXmlResource_Load(PyObject *self, PyObject *args, PyObject *kwargs) {
195 PyObject * _resultobj;
196 bool _result;
197 wxXmlResource * _arg0;
198 wxString * _arg1;
199 PyObject * _argo0 = 0;
200 PyObject * _obj1 = 0;
201 char *_kwnames[] = { "self","filemask", NULL };
202
203 self = self;
204 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_Load",_kwnames,&_argo0,&_obj1))
205 return NULL;
206 if (_argo0) {
207 if (_argo0 == Py_None) { _arg0 = NULL; }
208 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
209 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_Load. Expected _wxXmlResource_p.");
210 return NULL;
211 }
212 }
213{
c8bc7bb8
RD
214 _arg1 = wxString_in_helper(_obj1);
215 if (_arg1 == NULL)
d56cebe7 216 return NULL;
d56cebe7
RD
217}
218{
4268f798 219 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 220 _result = (bool )wxXmlResource_Load(_arg0,*_arg1);
d56cebe7 221
4268f798
RD
222 wxPyEndAllowThreads(__tstate);
223 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
224} _resultobj = Py_BuildValue("i",_result);
225{
226 if (_obj1)
227 delete _arg1;
228}
229 return _resultobj;
230}
231
cd834e7b
RD
232static bool wxXmlResource_LoadFromString(wxXmlResource *self,const wxString & data) {
233 static int s_memFileIdx = 0;
234
235 // Check for memory FS. If not present, load the handler:
236 wxMemoryFSHandler::AddFile(wxT("XRC_resource/dummy_file"),
237 wxT("dummy data"));
238 wxFileSystem fsys;
239 wxFSFile *f = fsys.OpenFile(wxT("memory:XRC_resource/dummy_file"));
240 wxMemoryFSHandler::RemoveFile(wxT("XRC_resource/dummy_file"));
241 if (f)
242 delete f;
243 else
244 wxFileSystem::AddHandler(new wxMemoryFSHandler);
245
246 // Now put the resource data into the memory FS
247 wxString filename(wxT("XRC_resource/data_string_"));
248 filename << s_memFileIdx;
249 s_memFileIdx += 1;
250 wxMemoryFSHandler::AddFile(filename, data);
251
252 // Load the "file" into the resource object
253 bool retval = self->Load(wxT("memory:") + filename );
254
255 return retval;
256 }
257static PyObject *_wrap_wxXmlResource_LoadFromString(PyObject *self, PyObject *args, PyObject *kwargs) {
258 PyObject * _resultobj;
259 bool _result;
260 wxXmlResource * _arg0;
261 wxString * _arg1;
262 PyObject * _argo0 = 0;
263 PyObject * _obj1 = 0;
264 char *_kwnames[] = { "self","data", NULL };
265
266 self = self;
267 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadFromString",_kwnames,&_argo0,&_obj1))
268 return NULL;
269 if (_argo0) {
270 if (_argo0 == Py_None) { _arg0 = NULL; }
271 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
272 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadFromString. Expected _wxXmlResource_p.");
273 return NULL;
274 }
275 }
276{
277 _arg1 = wxString_in_helper(_obj1);
278 if (_arg1 == NULL)
279 return NULL;
280}
281{
282 PyThreadState* __tstate = wxPyBeginAllowThreads();
283 _result = (bool )wxXmlResource_LoadFromString(_arg0,*_arg1);
284
285 wxPyEndAllowThreads(__tstate);
286 if (PyErr_Occurred()) return NULL;
287} _resultobj = Py_BuildValue("i",_result);
288{
289 if (_obj1)
290 delete _arg1;
291}
292 return _resultobj;
293}
294
d56cebe7
RD
295#define wxXmlResource_InitAllHandlers(_swigobj) (_swigobj->InitAllHandlers())
296static PyObject *_wrap_wxXmlResource_InitAllHandlers(PyObject *self, PyObject *args, PyObject *kwargs) {
297 PyObject * _resultobj;
298 wxXmlResource * _arg0;
299 PyObject * _argo0 = 0;
300 char *_kwnames[] = { "self", NULL };
301
302 self = self;
303 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_InitAllHandlers",_kwnames,&_argo0))
304 return NULL;
305 if (_argo0) {
306 if (_argo0 == Py_None) { _arg0 = NULL; }
307 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
308 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_InitAllHandlers. Expected _wxXmlResource_p.");
309 return NULL;
310 }
311 }
312{
4268f798 313 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 314 wxXmlResource_InitAllHandlers(_arg0);
d56cebe7 315
4268f798
RD
316 wxPyEndAllowThreads(__tstate);
317 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
318} Py_INCREF(Py_None);
319 _resultobj = Py_None;
320 return _resultobj;
321}
322
323#define wxXmlResource_AddHandler(_swigobj,_swigarg0) (_swigobj->AddHandler(_swigarg0))
324static PyObject *_wrap_wxXmlResource_AddHandler(PyObject *self, PyObject *args, PyObject *kwargs) {
325 PyObject * _resultobj;
326 wxXmlResource * _arg0;
327 wxXmlResourceHandler * _arg1;
328 PyObject * _argo0 = 0;
329 PyObject * _argo1 = 0;
330 char *_kwnames[] = { "self","handler", NULL };
331
332 self = self;
333 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_AddHandler",_kwnames,&_argo0,&_argo1))
334 return NULL;
335 if (_argo0) {
336 if (_argo0 == Py_None) { _arg0 = NULL; }
337 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
338 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_AddHandler. Expected _wxXmlResource_p.");
339 return NULL;
340 }
341 }
342 if (_argo1) {
343 if (_argo1 == Py_None) { _arg1 = NULL; }
344 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxXmlResourceHandler_p")) {
345 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_AddHandler. Expected _wxXmlResourceHandler_p.");
346 return NULL;
347 }
348 }
349{
4268f798 350 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 351 wxXmlResource_AddHandler(_arg0,_arg1);
d56cebe7 352
4268f798
RD
353 wxPyEndAllowThreads(__tstate);
354 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
355} Py_INCREF(Py_None);
356 _resultobj = Py_None;
357 return _resultobj;
358}
359
360#define wxXmlResource_ClearHandlers(_swigobj) (_swigobj->ClearHandlers())
361static PyObject *_wrap_wxXmlResource_ClearHandlers(PyObject *self, PyObject *args, PyObject *kwargs) {
362 PyObject * _resultobj;
363 wxXmlResource * _arg0;
364 PyObject * _argo0 = 0;
365 char *_kwnames[] = { "self", NULL };
366
367 self = self;
368 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_ClearHandlers",_kwnames,&_argo0))
369 return NULL;
370 if (_argo0) {
371 if (_argo0 == Py_None) { _arg0 = NULL; }
372 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
373 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_ClearHandlers. Expected _wxXmlResource_p.");
374 return NULL;
375 }
376 }
377{
4268f798 378 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 379 wxXmlResource_ClearHandlers(_arg0);
d56cebe7 380
4268f798
RD
381 wxPyEndAllowThreads(__tstate);
382 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
383} Py_INCREF(Py_None);
384 _resultobj = Py_None;
385 return _resultobj;
386}
387
388#define wxXmlResource_LoadMenu(_swigobj,_swigarg0) (_swigobj->LoadMenu(_swigarg0))
389static PyObject *_wrap_wxXmlResource_LoadMenu(PyObject *self, PyObject *args, PyObject *kwargs) {
390 PyObject * _resultobj;
391 wxMenu * _result;
392 wxXmlResource * _arg0;
393 wxString * _arg1;
394 PyObject * _argo0 = 0;
395 PyObject * _obj1 = 0;
396 char *_kwnames[] = { "self","name", NULL };
397
398 self = self;
399 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadMenu",_kwnames,&_argo0,&_obj1))
400 return NULL;
401 if (_argo0) {
402 if (_argo0 == Py_None) { _arg0 = NULL; }
403 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
404 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadMenu. Expected _wxXmlResource_p.");
405 return NULL;
406 }
407 }
408{
c8bc7bb8
RD
409 _arg1 = wxString_in_helper(_obj1);
410 if (_arg1 == NULL)
d56cebe7 411 return NULL;
d56cebe7
RD
412}
413{
4268f798 414 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 415 _result = (wxMenu *)wxXmlResource_LoadMenu(_arg0,*_arg1);
d56cebe7 416
4268f798
RD
417 wxPyEndAllowThreads(__tstate);
418 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
419}{ _resultobj = wxPyMake_wxObject(_result); }
420{
421 if (_obj1)
422 delete _arg1;
423}
424 return _resultobj;
425}
426
427#define wxXmlResource_LoadMenuBar(_swigobj,_swigarg0) (_swigobj->LoadMenuBar(_swigarg0))
428static PyObject *_wrap_wxXmlResource_LoadMenuBar(PyObject *self, PyObject *args, PyObject *kwargs) {
429 PyObject * _resultobj;
430 wxMenuBar * _result;
431 wxXmlResource * _arg0;
432 wxString * _arg1;
433 PyObject * _argo0 = 0;
434 PyObject * _obj1 = 0;
435 char *_kwnames[] = { "self","name", NULL };
436
437 self = self;
438 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadMenuBar",_kwnames,&_argo0,&_obj1))
439 return NULL;
440 if (_argo0) {
441 if (_argo0 == Py_None) { _arg0 = NULL; }
442 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
443 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadMenuBar. Expected _wxXmlResource_p.");
444 return NULL;
445 }
446 }
447{
c8bc7bb8
RD
448 _arg1 = wxString_in_helper(_obj1);
449 if (_arg1 == NULL)
d56cebe7 450 return NULL;
d56cebe7
RD
451}
452{
4268f798 453 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 454 _result = (wxMenuBar *)wxXmlResource_LoadMenuBar(_arg0,*_arg1);
d56cebe7 455
4268f798
RD
456 wxPyEndAllowThreads(__tstate);
457 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
458}{ _resultobj = wxPyMake_wxObject(_result); }
459{
460 if (_obj1)
461 delete _arg1;
462}
463 return _resultobj;
464}
465
32a85500
RD
466#define wxXmlResource_LoadMenuBarOnFrame(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadMenuBar(_swigarg0,_swigarg1))
467static PyObject *_wrap_wxXmlResource_LoadMenuBarOnFrame(PyObject *self, PyObject *args, PyObject *kwargs) {
468 PyObject * _resultobj;
469 wxMenuBar * _result;
470 wxXmlResource * _arg0;
471 wxWindow * _arg1;
472 wxString * _arg2;
473 PyObject * _argo0 = 0;
474 PyObject * _argo1 = 0;
475 PyObject * _obj2 = 0;
476 char *_kwnames[] = { "self","parent","name", NULL };
477
478 self = self;
479 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadMenuBarOnFrame",_kwnames,&_argo0,&_argo1,&_obj2))
480 return NULL;
481 if (_argo0) {
482 if (_argo0 == Py_None) { _arg0 = NULL; }
483 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
484 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadMenuBarOnFrame. Expected _wxXmlResource_p.");
485 return NULL;
486 }
487 }
488 if (_argo1) {
489 if (_argo1 == Py_None) { _arg1 = NULL; }
490 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) {
491 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadMenuBarOnFrame. Expected _wxWindow_p.");
492 return NULL;
493 }
494 }
495{
496 _arg2 = wxString_in_helper(_obj2);
497 if (_arg2 == NULL)
498 return NULL;
499}
500{
501 PyThreadState* __tstate = wxPyBeginAllowThreads();
502 _result = (wxMenuBar *)wxXmlResource_LoadMenuBarOnFrame(_arg0,_arg1,*_arg2);
503
504 wxPyEndAllowThreads(__tstate);
505 if (PyErr_Occurred()) return NULL;
506}{ _resultobj = wxPyMake_wxObject(_result); }
507{
508 if (_obj2)
509 delete _arg2;
510}
511 return _resultobj;
512}
513
d56cebe7
RD
514#define wxXmlResource_LoadToolBar(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadToolBar(_swigarg0,_swigarg1))
515static PyObject *_wrap_wxXmlResource_LoadToolBar(PyObject *self, PyObject *args, PyObject *kwargs) {
516 PyObject * _resultobj;
517 wxToolBar * _result;
518 wxXmlResource * _arg0;
519 wxWindow * _arg1;
520 wxString * _arg2;
521 PyObject * _argo0 = 0;
522 PyObject * _argo1 = 0;
523 PyObject * _obj2 = 0;
524 char *_kwnames[] = { "self","parent","name", NULL };
525
526 self = self;
527 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadToolBar",_kwnames,&_argo0,&_argo1,&_obj2))
528 return NULL;
529 if (_argo0) {
530 if (_argo0 == Py_None) { _arg0 = NULL; }
531 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
532 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadToolBar. Expected _wxXmlResource_p.");
533 return NULL;
534 }
535 }
536 if (_argo1) {
537 if (_argo1 == Py_None) { _arg1 = NULL; }
538 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) {
539 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadToolBar. Expected _wxWindow_p.");
540 return NULL;
541 }
542 }
543{
c8bc7bb8
RD
544 _arg2 = wxString_in_helper(_obj2);
545 if (_arg2 == NULL)
d56cebe7 546 return NULL;
d56cebe7
RD
547}
548{
4268f798 549 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 550 _result = (wxToolBar *)wxXmlResource_LoadToolBar(_arg0,_arg1,*_arg2);
d56cebe7 551
4268f798
RD
552 wxPyEndAllowThreads(__tstate);
553 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
554}{ _resultobj = wxPyMake_wxObject(_result); }
555{
556 if (_obj2)
557 delete _arg2;
558}
559 return _resultobj;
560}
561
562#define wxXmlResource_LoadDialog(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadDialog(_swigarg0,_swigarg1))
563static PyObject *_wrap_wxXmlResource_LoadDialog(PyObject *self, PyObject *args, PyObject *kwargs) {
564 PyObject * _resultobj;
565 wxDialog * _result;
566 wxXmlResource * _arg0;
567 wxWindow * _arg1;
568 wxString * _arg2;
569 PyObject * _argo0 = 0;
570 PyObject * _argo1 = 0;
571 PyObject * _obj2 = 0;
572 char *_kwnames[] = { "self","parent","name", NULL };
573 char _ptemp[128];
574
575 self = self;
576 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadDialog",_kwnames,&_argo0,&_argo1,&_obj2))
577 return NULL;
578 if (_argo0) {
579 if (_argo0 == Py_None) { _arg0 = NULL; }
580 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
581 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadDialog. Expected _wxXmlResource_p.");
582 return NULL;
583 }
584 }
585 if (_argo1) {
586 if (_argo1 == Py_None) { _arg1 = NULL; }
587 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) {
588 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadDialog. Expected _wxWindow_p.");
589 return NULL;
590 }
591 }
592{
c8bc7bb8
RD
593 _arg2 = wxString_in_helper(_obj2);
594 if (_arg2 == NULL)
d56cebe7 595 return NULL;
d56cebe7
RD
596}
597{
4268f798 598 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 599 _result = (wxDialog *)wxXmlResource_LoadDialog(_arg0,_arg1,*_arg2);
d56cebe7 600
4268f798
RD
601 wxPyEndAllowThreads(__tstate);
602 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
603} if (_result) {
604 SWIG_MakePtr(_ptemp, (char *) _result,"_wxDialog_p");
605 _resultobj = Py_BuildValue("s",_ptemp);
606 } else {
607 Py_INCREF(Py_None);
608 _resultobj = Py_None;
609 }
610{
611 if (_obj2)
612 delete _arg2;
613}
614 return _resultobj;
615}
616
617#define wxXmlResource_LoadOnDialog(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->LoadDialog(_swigarg0,_swigarg1,_swigarg2))
618static PyObject *_wrap_wxXmlResource_LoadOnDialog(PyObject *self, PyObject *args, PyObject *kwargs) {
619 PyObject * _resultobj;
620 bool _result;
621 wxXmlResource * _arg0;
622 wxDialog * _arg1;
623 wxWindow * _arg2;
624 wxString * _arg3;
625 PyObject * _argo0 = 0;
626 PyObject * _argo1 = 0;
627 PyObject * _argo2 = 0;
628 PyObject * _obj3 = 0;
629 char *_kwnames[] = { "self","dlg","parent","name", NULL };
630
631 self = self;
632 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOOO:wxXmlResource_LoadOnDialog",_kwnames,&_argo0,&_argo1,&_argo2,&_obj3))
633 return NULL;
634 if (_argo0) {
635 if (_argo0 == Py_None) { _arg0 = NULL; }
636 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
637 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadOnDialog. Expected _wxXmlResource_p.");
638 return NULL;
639 }
640 }
641 if (_argo1) {
642 if (_argo1 == Py_None) { _arg1 = NULL; }
643 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxDialog_p")) {
644 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadOnDialog. Expected _wxDialog_p.");
645 return NULL;
646 }
647 }
648 if (_argo2) {
649 if (_argo2 == Py_None) { _arg2 = NULL; }
650 else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) {
651 PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_LoadOnDialog. Expected _wxWindow_p.");
652 return NULL;
653 }
654 }
655{
c8bc7bb8
RD
656 _arg3 = wxString_in_helper(_obj3);
657 if (_arg3 == NULL)
d56cebe7 658 return NULL;
d56cebe7
RD
659}
660{
4268f798 661 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 662 _result = (bool )wxXmlResource_LoadOnDialog(_arg0,_arg1,_arg2,*_arg3);
d56cebe7 663
4268f798
RD
664 wxPyEndAllowThreads(__tstate);
665 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
666} _resultobj = Py_BuildValue("i",_result);
667{
668 if (_obj3)
669 delete _arg3;
670}
671 return _resultobj;
672}
673
674#define wxXmlResource_LoadPanel(_swigobj,_swigarg0,_swigarg1) (_swigobj->LoadPanel(_swigarg0,_swigarg1))
675static PyObject *_wrap_wxXmlResource_LoadPanel(PyObject *self, PyObject *args, PyObject *kwargs) {
676 PyObject * _resultobj;
677 wxPanel * _result;
678 wxXmlResource * _arg0;
679 wxWindow * _arg1;
680 wxString * _arg2;
681 PyObject * _argo0 = 0;
682 PyObject * _argo1 = 0;
683 PyObject * _obj2 = 0;
684 char *_kwnames[] = { "self","parent","name", NULL };
685 char _ptemp[128];
686
687 self = self;
688 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO:wxXmlResource_LoadPanel",_kwnames,&_argo0,&_argo1,&_obj2))
689 return NULL;
690 if (_argo0) {
691 if (_argo0 == Py_None) { _arg0 = NULL; }
692 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
693 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadPanel. Expected _wxXmlResource_p.");
694 return NULL;
695 }
696 }
697 if (_argo1) {
698 if (_argo1 == Py_None) { _arg1 = NULL; }
699 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxWindow_p")) {
700 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadPanel. Expected _wxWindow_p.");
701 return NULL;
702 }
703 }
704{
c8bc7bb8
RD
705 _arg2 = wxString_in_helper(_obj2);
706 if (_arg2 == NULL)
d56cebe7 707 return NULL;
d56cebe7
RD
708}
709{
4268f798 710 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 711 _result = (wxPanel *)wxXmlResource_LoadPanel(_arg0,_arg1,*_arg2);
d56cebe7 712
4268f798
RD
713 wxPyEndAllowThreads(__tstate);
714 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
715} if (_result) {
716 SWIG_MakePtr(_ptemp, (char *) _result,"_wxPanel_p");
717 _resultobj = Py_BuildValue("s",_ptemp);
718 } else {
719 Py_INCREF(Py_None);
720 _resultobj = Py_None;
721 }
722{
723 if (_obj2)
724 delete _arg2;
725}
726 return _resultobj;
727}
728
729#define wxXmlResource_LoadOnPanel(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->LoadPanel(_swigarg0,_swigarg1,_swigarg2))
730static PyObject *_wrap_wxXmlResource_LoadOnPanel(PyObject *self, PyObject *args, PyObject *kwargs) {
731 PyObject * _resultobj;
732 bool _result;
733 wxXmlResource * _arg0;
734 wxPanel * _arg1;
735 wxWindow * _arg2;
736 wxString * _arg3;
737 PyObject * _argo0 = 0;
738 PyObject * _argo1 = 0;
739 PyObject * _argo2 = 0;
740 PyObject * _obj3 = 0;
741 char *_kwnames[] = { "self","panel","parent","name", NULL };
742
743 self = self;
744 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOOO:wxXmlResource_LoadOnPanel",_kwnames,&_argo0,&_argo1,&_argo2,&_obj3))
745 return NULL;
746 if (_argo0) {
747 if (_argo0 == Py_None) { _arg0 = NULL; }
748 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
749 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadOnPanel. Expected _wxXmlResource_p.");
750 return NULL;
751 }
752 }
753 if (_argo1) {
754 if (_argo1 == Py_None) { _arg1 = NULL; }
755 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxPanel_p")) {
756 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadOnPanel. Expected _wxPanel_p.");
757 return NULL;
758 }
759 }
760 if (_argo2) {
761 if (_argo2 == Py_None) { _arg2 = NULL; }
762 else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) {
763 PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_LoadOnPanel. Expected _wxWindow_p.");
764 return NULL;
765 }
766 }
767{
c8bc7bb8
RD
768 _arg3 = wxString_in_helper(_obj3);
769 if (_arg3 == NULL)
d56cebe7 770 return NULL;
d56cebe7
RD
771}
772{
4268f798 773 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 774 _result = (bool )wxXmlResource_LoadOnPanel(_arg0,_arg1,_arg2,*_arg3);
d56cebe7 775
4268f798
RD
776 wxPyEndAllowThreads(__tstate);
777 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
778} _resultobj = Py_BuildValue("i",_result);
779{
780 if (_obj3)
781 delete _arg3;
782}
783 return _resultobj;
784}
785
786#define wxXmlResource_LoadFrame(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->LoadFrame(_swigarg0,_swigarg1,_swigarg2))
787static PyObject *_wrap_wxXmlResource_LoadFrame(PyObject *self, PyObject *args, PyObject *kwargs) {
788 PyObject * _resultobj;
789 bool _result;
790 wxXmlResource * _arg0;
791 wxFrame * _arg1;
792 wxWindow * _arg2;
793 wxString * _arg3;
794 PyObject * _argo0 = 0;
795 PyObject * _argo1 = 0;
796 PyObject * _argo2 = 0;
797 PyObject * _obj3 = 0;
798 char *_kwnames[] = { "self","frame","parent","name", NULL };
799
800 self = self;
801 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOOO:wxXmlResource_LoadFrame",_kwnames,&_argo0,&_argo1,&_argo2,&_obj3))
802 return NULL;
803 if (_argo0) {
804 if (_argo0 == Py_None) { _arg0 = NULL; }
805 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
806 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadFrame. Expected _wxXmlResource_p.");
807 return NULL;
808 }
809 }
810 if (_argo1) {
811 if (_argo1 == Py_None) { _arg1 = NULL; }
812 else if (SWIG_GetPtrObj(_argo1,(void **) &_arg1,"_wxFrame_p")) {
813 PyErr_SetString(PyExc_TypeError,"Type error in argument 2 of wxXmlResource_LoadFrame. Expected _wxFrame_p.");
814 return NULL;
815 }
816 }
817 if (_argo2) {
818 if (_argo2 == Py_None) { _arg2 = NULL; }
819 else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) {
820 PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_LoadFrame. Expected _wxWindow_p.");
821 return NULL;
822 }
823 }
824{
c8bc7bb8
RD
825 _arg3 = wxString_in_helper(_obj3);
826 if (_arg3 == NULL)
d56cebe7 827 return NULL;
d56cebe7
RD
828}
829{
4268f798 830 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 831 _result = (bool )wxXmlResource_LoadFrame(_arg0,_arg1,_arg2,*_arg3);
d56cebe7 832
4268f798
RD
833 wxPyEndAllowThreads(__tstate);
834 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
835} _resultobj = Py_BuildValue("i",_result);
836{
837 if (_obj3)
838 delete _arg3;
839}
840 return _resultobj;
841}
842
843#define wxXmlResource_LoadBitmap(_swigobj,_swigarg0) (_swigobj->LoadBitmap(_swigarg0))
844static PyObject *_wrap_wxXmlResource_LoadBitmap(PyObject *self, PyObject *args, PyObject *kwargs) {
845 PyObject * _resultobj;
846 wxBitmap * _result;
847 wxXmlResource * _arg0;
848 wxString * _arg1;
849 PyObject * _argo0 = 0;
850 PyObject * _obj1 = 0;
851 char *_kwnames[] = { "self","name", NULL };
852 char _ptemp[128];
853
854 self = self;
855 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadBitmap",_kwnames,&_argo0,&_obj1))
856 return NULL;
857 if (_argo0) {
858 if (_argo0 == Py_None) { _arg0 = NULL; }
859 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
860 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadBitmap. Expected _wxXmlResource_p.");
861 return NULL;
862 }
863 }
864{
c8bc7bb8
RD
865 _arg1 = wxString_in_helper(_obj1);
866 if (_arg1 == NULL)
d56cebe7 867 return NULL;
d56cebe7
RD
868}
869{
4268f798 870 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 871 _result = new wxBitmap (wxXmlResource_LoadBitmap(_arg0,*_arg1));
d56cebe7 872
4268f798
RD
873 wxPyEndAllowThreads(__tstate);
874 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
875} SWIG_MakePtr(_ptemp, (void *) _result,"_wxBitmap_p");
876 _resultobj = Py_BuildValue("s",_ptemp);
877{
878 if (_obj1)
879 delete _arg1;
880}
881 return _resultobj;
882}
883
884#define wxXmlResource_LoadIcon(_swigobj,_swigarg0) (_swigobj->LoadIcon(_swigarg0))
885static PyObject *_wrap_wxXmlResource_LoadIcon(PyObject *self, PyObject *args, PyObject *kwargs) {
886 PyObject * _resultobj;
887 wxIcon * _result;
888 wxXmlResource * _arg0;
889 wxString * _arg1;
890 PyObject * _argo0 = 0;
891 PyObject * _obj1 = 0;
892 char *_kwnames[] = { "self","name", NULL };
893 char _ptemp[128];
894
895 self = self;
896 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OO:wxXmlResource_LoadIcon",_kwnames,&_argo0,&_obj1))
897 return NULL;
898 if (_argo0) {
899 if (_argo0 == Py_None) { _arg0 = NULL; }
900 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
901 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_LoadIcon. Expected _wxXmlResource_p.");
902 return NULL;
903 }
904 }
905{
c8bc7bb8
RD
906 _arg1 = wxString_in_helper(_obj1);
907 if (_arg1 == NULL)
d56cebe7 908 return NULL;
d56cebe7
RD
909}
910{
4268f798 911 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 912 _result = new wxIcon (wxXmlResource_LoadIcon(_arg0,*_arg1));
d56cebe7 913
4268f798
RD
914 wxPyEndAllowThreads(__tstate);
915 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
916} SWIG_MakePtr(_ptemp, (void *) _result,"_wxIcon_p");
917 _resultobj = Py_BuildValue("s",_ptemp);
918{
919 if (_obj1)
920 delete _arg1;
921}
922 return _resultobj;
923}
924
925#define wxXmlResource_AttachUnknownControl(_swigobj,_swigarg0,_swigarg1,_swigarg2) (_swigobj->AttachUnknownControl(_swigarg0,_swigarg1,_swigarg2))
926static PyObject *_wrap_wxXmlResource_AttachUnknownControl(PyObject *self, PyObject *args, PyObject *kwargs) {
927 PyObject * _resultobj;
928 bool _result;
929 wxXmlResource * _arg0;
930 wxString * _arg1;
931 wxWindow * _arg2;
932 wxWindow * _arg3 = (wxWindow *) NULL;
933 PyObject * _argo0 = 0;
934 PyObject * _obj1 = 0;
935 PyObject * _argo2 = 0;
936 PyObject * _argo3 = 0;
937 char *_kwnames[] = { "self","name","control","parent", NULL };
938
939 self = self;
940 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"OOO|O:wxXmlResource_AttachUnknownControl",_kwnames,&_argo0,&_obj1,&_argo2,&_argo3))
941 return NULL;
942 if (_argo0) {
943 if (_argo0 == Py_None) { _arg0 = NULL; }
944 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
945 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_AttachUnknownControl. Expected _wxXmlResource_p.");
946 return NULL;
947 }
948 }
949{
c8bc7bb8
RD
950 _arg1 = wxString_in_helper(_obj1);
951 if (_arg1 == NULL)
d56cebe7 952 return NULL;
d56cebe7
RD
953}
954 if (_argo2) {
955 if (_argo2 == Py_None) { _arg2 = NULL; }
956 else if (SWIG_GetPtrObj(_argo2,(void **) &_arg2,"_wxWindow_p")) {
957 PyErr_SetString(PyExc_TypeError,"Type error in argument 3 of wxXmlResource_AttachUnknownControl. Expected _wxWindow_p.");
958 return NULL;
959 }
960 }
961 if (_argo3) {
962 if (_argo3 == Py_None) { _arg3 = NULL; }
963 else if (SWIG_GetPtrObj(_argo3,(void **) &_arg3,"_wxWindow_p")) {
964 PyErr_SetString(PyExc_TypeError,"Type error in argument 4 of wxXmlResource_AttachUnknownControl. Expected _wxWindow_p.");
965 return NULL;
966 }
967 }
968{
4268f798 969 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 970 _result = (bool )wxXmlResource_AttachUnknownControl(_arg0,*_arg1,_arg2,_arg3);
d56cebe7 971
4268f798
RD
972 wxPyEndAllowThreads(__tstate);
973 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
974} _resultobj = Py_BuildValue("i",_result);
975{
976 if (_obj1)
977 delete _arg1;
978}
979 return _resultobj;
980}
981
c6c593e8 982static PyObject *_wrap_wxXmlResource_GetXRCID(PyObject *self, PyObject *args, PyObject *kwargs) {
d56cebe7
RD
983 PyObject * _resultobj;
984 int _result;
1496068d
RD
985 wxString * _arg0;
986 PyObject * _obj0 = 0;
d56cebe7
RD
987 char *_kwnames[] = { "str_id", NULL };
988
989 self = self;
1496068d 990 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_GetXRCID",_kwnames,&_obj0))
d56cebe7 991 return NULL;
1496068d
RD
992{
993 _arg0 = wxString_in_helper(_obj0);
994 if (_arg0 == NULL)
995 return NULL;
996}
d56cebe7 997{
4268f798 998 PyThreadState* __tstate = wxPyBeginAllowThreads();
1496068d 999 _result = (int )wxXmlResource::GetXRCID(*_arg0);
d56cebe7 1000
4268f798
RD
1001 wxPyEndAllowThreads(__tstate);
1002 if (PyErr_Occurred()) return NULL;
d56cebe7 1003} _resultobj = Py_BuildValue("i",_result);
1496068d
RD
1004{
1005 if (_obj0)
1006 delete _arg0;
1007}
d56cebe7
RD
1008 return _resultobj;
1009}
1010
1011#define wxXmlResource_GetVersion(_swigobj) (_swigobj->GetVersion())
1012static PyObject *_wrap_wxXmlResource_GetVersion(PyObject *self, PyObject *args, PyObject *kwargs) {
1013 PyObject * _resultobj;
1014 long _result;
1015 wxXmlResource * _arg0;
1016 PyObject * _argo0 = 0;
1017 char *_kwnames[] = { "self", NULL };
1018
1019 self = self;
1020 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_GetVersion",_kwnames,&_argo0))
1021 return NULL;
1022 if (_argo0) {
1023 if (_argo0 == Py_None) { _arg0 = NULL; }
1024 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
1025 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_GetVersion. Expected _wxXmlResource_p.");
1026 return NULL;
1027 }
1028 }
1029{
4268f798 1030 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 1031 _result = (long )wxXmlResource_GetVersion(_arg0);
d56cebe7 1032
4268f798
RD
1033 wxPyEndAllowThreads(__tstate);
1034 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
1035} _resultobj = Py_BuildValue("l",_result);
1036 return _resultobj;
1037}
1038
1039#define wxXmlResource_CompareVersion(_swigobj,_swigarg0,_swigarg1,_swigarg2,_swigarg3) (_swigobj->CompareVersion(_swigarg0,_swigarg1,_swigarg2,_swigarg3))
1040static PyObject *_wrap_wxXmlResource_CompareVersion(PyObject *self, PyObject *args, PyObject *kwargs) {
1041 PyObject * _resultobj;
1042 int _result;
1043 wxXmlResource * _arg0;
1044 int _arg1;
1045 int _arg2;
1046 int _arg3;
1047 int _arg4;
1048 PyObject * _argo0 = 0;
1049 char *_kwnames[] = { "self","major","minor","release","revision", NULL };
1050
1051 self = self;
1052 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"Oiiii:wxXmlResource_CompareVersion",_kwnames,&_argo0,&_arg1,&_arg2,&_arg3,&_arg4))
1053 return NULL;
1054 if (_argo0) {
1055 if (_argo0 == Py_None) { _arg0 = NULL; }
1056 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
1057 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_CompareVersion. Expected _wxXmlResource_p.");
1058 return NULL;
1059 }
1060 }
1061{
4268f798 1062 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 1063 _result = (int )wxXmlResource_CompareVersion(_arg0,_arg1,_arg2,_arg3,_arg4);
d56cebe7 1064
4268f798
RD
1065 wxPyEndAllowThreads(__tstate);
1066 if (PyErr_Occurred()) return NULL;
d56cebe7
RD
1067} _resultobj = Py_BuildValue("i",_result);
1068 return _resultobj;
1069}
1070
ce914f73
RD
1071static PyObject *_wrap_wxXmlResource_Get(PyObject *self, PyObject *args, PyObject *kwargs) {
1072 PyObject * _resultobj;
1073 wxXmlResource * _result;
1074 char *_kwnames[] = { NULL };
1075 char _ptemp[128];
1076
1077 self = self;
1078 if(!PyArg_ParseTupleAndKeywords(args,kwargs,":wxXmlResource_Get",_kwnames))
1079 return NULL;
1080{
1081 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 1082 _result = (wxXmlResource *)wxXmlResource::Get();
ce914f73
RD
1083
1084 wxPyEndAllowThreads(__tstate);
1085 if (PyErr_Occurred()) return NULL;
1086} if (_result) {
1087 SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p");
1088 _resultobj = Py_BuildValue("s",_ptemp);
1089 } else {
1090 Py_INCREF(Py_None);
1091 _resultobj = Py_None;
1092 }
1093 return _resultobj;
1094}
1095
1096static PyObject *_wrap_wxXmlResource_Set(PyObject *self, PyObject *args, PyObject *kwargs) {
1097 PyObject * _resultobj;
1098 wxXmlResource * _result;
1099 wxXmlResource * _arg0;
1100 PyObject * _argo0 = 0;
1101 char *_kwnames[] = { "res", NULL };
1102 char _ptemp[128];
1103
1104 self = self;
1105 if(!PyArg_ParseTupleAndKeywords(args,kwargs,"O:wxXmlResource_Set",_kwnames,&_argo0))
1106 return NULL;
1107 if (_argo0) {
1108 if (_argo0 == Py_None) { _arg0 = NULL; }
1109 else if (SWIG_GetPtrObj(_argo0,(void **) &_arg0,"_wxXmlResource_p")) {
1110 PyErr_SetString(PyExc_TypeError,"Type error in argument 1 of wxXmlResource_Set. Expected _wxXmlResource_p.");
1111 return NULL;
1112 }
1113 }
1114{
1115 PyThreadState* __tstate = wxPyBeginAllowThreads();
c8bc7bb8 1116 _result = (wxXmlResource *)wxXmlResource::Set(_arg0);
ce914f73
RD
1117
1118 wxPyEndAllowThreads(__tstate);
1119 if (PyErr_Occurred()) return NULL;
1120} if (_result) {
1121 SWIG_MakePtr(_ptemp, (char *) _result,"_wxXmlResource_p");
1122 _resultobj = Py_BuildValue("s",_ptemp);
1123 } else {
1124 Py_INCREF(Py_None);
1125 _resultobj = Py_None;
1126 }
1127 return _resultobj;
1128}
1129
d56cebe7 1130static PyMethodDef xrccMethods[] = {
ce914f73
RD
1131 { "wxXmlResource_Set", (PyCFunction) _wrap_wxXmlResource_Set, METH_VARARGS | METH_KEYWORDS },
1132 { "wxXmlResource_Get", (PyCFunction) _wrap_wxXmlResource_Get, METH_VARARGS | METH_KEYWORDS },
d56cebe7
RD
1133 { "wxXmlResource_CompareVersion", (PyCFunction) _wrap_wxXmlResource_CompareVersion, METH_VARARGS | METH_KEYWORDS },
1134 { "wxXmlResource_GetVersion", (PyCFunction) _wrap_wxXmlResource_GetVersion, METH_VARARGS | METH_KEYWORDS },
c6c593e8 1135 { "wxXmlResource_GetXRCID", (PyCFunction) _wrap_wxXmlResource_GetXRCID, METH_VARARGS | METH_KEYWORDS },
d56cebe7
RD
1136 { "wxXmlResource_AttachUnknownControl", (PyCFunction) _wrap_wxXmlResource_AttachUnknownControl, METH_VARARGS | METH_KEYWORDS },
1137 { "wxXmlResource_LoadIcon", (PyCFunction) _wrap_wxXmlResource_LoadIcon, METH_VARARGS | METH_KEYWORDS },
1138 { "wxXmlResource_LoadBitmap", (PyCFunction) _wrap_wxXmlResource_LoadBitmap, METH_VARARGS | METH_KEYWORDS },
1139 { "wxXmlResource_LoadFrame", (PyCFunction) _wrap_wxXmlResource_LoadFrame, METH_VARARGS | METH_KEYWORDS },
1140 { "wxXmlResource_LoadOnPanel", (PyCFunction) _wrap_wxXmlResource_LoadOnPanel, METH_VARARGS | METH_KEYWORDS },
1141 { "wxXmlResource_LoadPanel", (PyCFunction) _wrap_wxXmlResource_LoadPanel, METH_VARARGS | METH_KEYWORDS },
1142 { "wxXmlResource_LoadOnDialog", (PyCFunction) _wrap_wxXmlResource_LoadOnDialog, METH_VARARGS | METH_KEYWORDS },
1143 { "wxXmlResource_LoadDialog", (PyCFunction) _wrap_wxXmlResource_LoadDialog, METH_VARARGS | METH_KEYWORDS },
1144 { "wxXmlResource_LoadToolBar", (PyCFunction) _wrap_wxXmlResource_LoadToolBar, METH_VARARGS | METH_KEYWORDS },
32a85500 1145 { "wxXmlResource_LoadMenuBarOnFrame", (PyCFunction) _wrap_wxXmlResource_LoadMenuBarOnFrame, METH_VARARGS | METH_KEYWORDS },
d56cebe7
RD
1146 { "wxXmlResource_LoadMenuBar", (PyCFunction) _wrap_wxXmlResource_LoadMenuBar, METH_VARARGS | METH_KEYWORDS },
1147 { "wxXmlResource_LoadMenu", (PyCFunction) _wrap_wxXmlResource_LoadMenu, METH_VARARGS | METH_KEYWORDS },
1148 { "wxXmlResource_ClearHandlers", (PyCFunction) _wrap_wxXmlResource_ClearHandlers, METH_VARARGS | METH_KEYWORDS },
1149 { "wxXmlResource_AddHandler", (PyCFunction) _wrap_wxXmlResource_AddHandler, METH_VARARGS | METH_KEYWORDS },
1150 { "wxXmlResource_InitAllHandlers", (PyCFunction) _wrap_wxXmlResource_InitAllHandlers, METH_VARARGS | METH_KEYWORDS },
cd834e7b 1151 { "wxXmlResource_LoadFromString", (PyCFunction) _wrap_wxXmlResource_LoadFromString, METH_VARARGS | METH_KEYWORDS },
d56cebe7
RD
1152 { "wxXmlResource_Load", (PyCFunction) _wrap_wxXmlResource_Load, METH_VARARGS | METH_KEYWORDS },
1153 { "delete_wxXmlResource", (PyCFunction) _wrap_delete_wxXmlResource, METH_VARARGS | METH_KEYWORDS },
cd834e7b 1154 { "new_wxEmptyXmlResource", (PyCFunction) _wrap_new_wxEmptyXmlResource, METH_VARARGS | METH_KEYWORDS },
d56cebe7 1155 { "new_wxXmlResource", (PyCFunction) _wrap_new_wxXmlResource, METH_VARARGS | METH_KEYWORDS },
d56cebe7
RD
1156 { NULL, NULL }
1157};
1158#ifdef __cplusplus
1159}
1160#endif
1161/*
1162 * This table is used by the pointer type-checker
1163 */
1164static struct { char *n1; char *n2; void *(*pcnv)(void *); } _swig_mapping[] = {
1165 { "_signed_long","_long",0},
1166 { "_wxPrintQuality","_wxCoord",0},
1167 { "_wxPrintQuality","_int",0},
1168 { "_wxPrintQuality","_signed_int",0},
1169 { "_wxPrintQuality","_unsigned_int",0},
1170 { "_wxPrintQuality","_wxWindowID",0},
1171 { "_wxPrintQuality","_uint",0},
1172 { "_wxPrintQuality","_EBool",0},
1173 { "_wxPrintQuality","_size_t",0},
1174 { "_wxPrintQuality","_time_t",0},
1175 { "_byte","_unsigned_char",0},
1176 { "_long","_unsigned_long",0},
1177 { "_long","_signed_long",0},
1178 { "_size_t","_wxCoord",0},
1179 { "_size_t","_wxPrintQuality",0},
1180 { "_size_t","_time_t",0},
1181 { "_size_t","_unsigned_int",0},
1182 { "_size_t","_int",0},
1183 { "_size_t","_wxWindowID",0},
1184 { "_size_t","_uint",0},
1185 { "_uint","_wxCoord",0},
1186 { "_uint","_wxPrintQuality",0},
1187 { "_uint","_time_t",0},
1188 { "_uint","_size_t",0},
1189 { "_uint","_unsigned_int",0},
1190 { "_uint","_int",0},
1191 { "_uint","_wxWindowID",0},
1192 { "_wxChar","_char",0},
1193 { "_char","_wxChar",0},
65fe3842 1194 { "_struct_wxNativeFontInfo","_wxNativeFontInfo",0},
d56cebe7
RD
1195 { "_EBool","_wxCoord",0},
1196 { "_EBool","_wxPrintQuality",0},
1197 { "_EBool","_signed_int",0},
1198 { "_EBool","_int",0},
1199 { "_EBool","_wxWindowID",0},
1200 { "_unsigned_long","_long",0},
65fe3842 1201 { "_wxNativeFontInfo","_struct_wxNativeFontInfo",0},
d56cebe7
RD
1202 { "_signed_int","_wxCoord",0},
1203 { "_signed_int","_wxPrintQuality",0},
1204 { "_signed_int","_EBool",0},
1205 { "_signed_int","_wxWindowID",0},
1206 { "_signed_int","_int",0},
1207 { "_WXTYPE","_wxDateTime_t",0},
1208 { "_WXTYPE","_short",0},
1209 { "_WXTYPE","_signed_short",0},
1210 { "_WXTYPE","_unsigned_short",0},
1211 { "_unsigned_short","_wxDateTime_t",0},
1212 { "_unsigned_short","_WXTYPE",0},
1213 { "_unsigned_short","_short",0},
1214 { "_wxObject","_wxXmlResource",SwigwxXmlResourceTowxObject},
1215 { "_signed_short","_WXTYPE",0},
1216 { "_signed_short","_short",0},
1217 { "_unsigned_char","_byte",0},
1218 { "_unsigned_int","_wxCoord",0},
1219 { "_unsigned_int","_wxPrintQuality",0},
1220 { "_unsigned_int","_time_t",0},
1221 { "_unsigned_int","_size_t",0},
1222 { "_unsigned_int","_uint",0},
1223 { "_unsigned_int","_wxWindowID",0},
1224 { "_unsigned_int","_int",0},
1225 { "_short","_wxDateTime_t",0},
1226 { "_short","_WXTYPE",0},
1227 { "_short","_unsigned_short",0},
1228 { "_short","_signed_short",0},
1229 { "_wxWindowID","_wxCoord",0},
1230 { "_wxWindowID","_wxPrintQuality",0},
1231 { "_wxWindowID","_time_t",0},
1232 { "_wxWindowID","_size_t",0},
1233 { "_wxWindowID","_EBool",0},
1234 { "_wxWindowID","_uint",0},
1235 { "_wxWindowID","_int",0},
1236 { "_wxWindowID","_signed_int",0},
1237 { "_wxWindowID","_unsigned_int",0},
1238 { "_int","_wxCoord",0},
1239 { "_int","_wxPrintQuality",0},
1240 { "_int","_time_t",0},
1241 { "_int","_size_t",0},
1242 { "_int","_EBool",0},
1243 { "_int","_uint",0},
1244 { "_int","_wxWindowID",0},
1245 { "_int","_unsigned_int",0},
1246 { "_int","_signed_int",0},
1247 { "_wxDateTime_t","_unsigned_short",0},
1248 { "_wxDateTime_t","_short",0},
1249 { "_wxDateTime_t","_WXTYPE",0},
1250 { "_time_t","_wxCoord",0},
1251 { "_time_t","_wxPrintQuality",0},
1252 { "_time_t","_unsigned_int",0},
1253 { "_time_t","_int",0},
1254 { "_time_t","_wxWindowID",0},
1255 { "_time_t","_uint",0},
1256 { "_time_t","_size_t",0},
1257 { "_wxCoord","_int",0},
1258 { "_wxCoord","_signed_int",0},
1259 { "_wxCoord","_unsigned_int",0},
1260 { "_wxCoord","_wxWindowID",0},
1261 { "_wxCoord","_uint",0},
1262 { "_wxCoord","_EBool",0},
1263 { "_wxCoord","_size_t",0},
1264 { "_wxCoord","_time_t",0},
1265 { "_wxCoord","_wxPrintQuality",0},
1266{0,0,0}};
1267
1268static PyObject *SWIG_globals;
1269#ifdef __cplusplus
1270extern "C"
1271#endif
1272SWIGEXPORT(void) initxrcc() {
1273 PyObject *m, *d;
1274 SWIG_globals = SWIG_newvarlink();
1275 m = Py_InitModule("xrcc", xrccMethods);
1276 d = PyModule_GetDict(m);
b5a5d647
RD
1277 PyDict_SetItemString(d,"wxXRC_USE_LOCALE", PyInt_FromLong((long) wxXRC_USE_LOCALE));
1278 PyDict_SetItemString(d,"wxXRC_NO_SUBCLASSING", PyInt_FromLong((long) wxXRC_NO_SUBCLASSING));
d56cebe7
RD
1279
1280
1281 wxClassInfo::CleanUpClasses();
1282 wxClassInfo::InitializeClasses();
1283
d56cebe7 1284 wxXmlInitResourceModule();
ce914f73 1285 wxXmlResource::Get()->InitAllHandlers();
d56cebe7
RD
1286
1287{
1288 int i;
1289 for (i = 0; _swig_mapping[i].n1; i++)
1290 SWIG_RegisterMapping(_swig_mapping[i].n1,_swig_mapping[i].n2,_swig_mapping[i].pcnv);
1291}
1292}