Files
Phoenix/sip/cpp/sip_corewxHelpEvent.cpp
Robin Dunn 62e8448d8e regenerated sip and c++ files
git-svn-id: https://svn.wxwidgets.org/svn/wx/sandbox/trunk/Phoenix@66198 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
2010-11-18 08:32:48 +00:00

441 lines
12 KiB
C++

/*
* Interface wrapper code.
*
* Generated by SIP 4.12-snapshot-93040d2c716c
*
* Copyright: (c) 2010 by Total Control Software
* License: wxWindows License
*/
#include "sipAPI_core.h"
#line 512 "sip/gen/event.sip"
#include <wx/event.h>
#line 15 "sip_corewxHelpEvent.cpp"
#line 23 "sip/gen/gdicmn.sip"
#include <wx/gdicmn.h>
#line 19 "sip_corewxHelpEvent.cpp"
#line 40 "sip/gen/object.sip"
#include <wx/object.h>
#line 22 "sip_corewxHelpEvent.cpp"
#line 129 "sip/gen/event.sip"
#include <wx/event.h>
#line 25 "sip_corewxHelpEvent.cpp"
#line 17 "sip/gen/object.sip"
#include <wx/object.h>
#line 28 "sip_corewxHelpEvent.cpp"
#line 84 "sip/gen/object.sip"
#include <wx/object.h>
#line 31 "sip_corewxHelpEvent.cpp"
class sipwxHelpEvent : public wxHelpEvent
{
public:
sipwxHelpEvent(wxEventType,wxWindowID,const wxPoint&,wxHelpEvent::Origin);
sipwxHelpEvent(const wxHelpEvent&);
virtual ~sipwxHelpEvent();
/*
* There is a protected method for every virtual method visible from
* this class.
*/
protected:
wxEvent * Clone();
wxEventCategory GetEventCategory();
wxClassInfo * GetClassInfo();
public:
sipSimpleWrapper *sipPySelf;
private:
sipwxHelpEvent(const sipwxHelpEvent &);
sipwxHelpEvent &operator = (const sipwxHelpEvent &);
char sipPyMethods[3];
};
sipwxHelpEvent::sipwxHelpEvent(wxEventType type,wxWindowID winid,const wxPoint& pt,wxHelpEvent::Origin origin): wxHelpEvent(type,winid,pt,origin), sipPySelf(0)
{
memset(sipPyMethods, 0, sizeof (sipPyMethods));
}
sipwxHelpEvent::sipwxHelpEvent(const wxHelpEvent& a0): wxHelpEvent(a0), sipPySelf(0)
{
memset(sipPyMethods, 0, sizeof (sipPyMethods));
}
sipwxHelpEvent::~sipwxHelpEvent()
{
sipCommonDtor(sipPySelf);
}
wxEvent * sipwxHelpEvent::Clone()
{
sip_gilstate_t sipGILState;
PyObject *sipMeth;
sipMeth = sipIsPyMethod(&sipGILState,&sipPyMethods[0],sipPySelf,NULL,sipName_Clone);
if (!sipMeth)
return wxEvent::Clone();
extern wxEvent * sipVH__core_1(sip_gilstate_t,PyObject *);
return sipVH__core_1(sipGILState,sipMeth);
}
wxEventCategory sipwxHelpEvent::GetEventCategory()
{
sip_gilstate_t sipGILState;
PyObject *sipMeth;
sipMeth = sipIsPyMethod(&sipGILState,&sipPyMethods[1],sipPySelf,NULL,sipName_GetEventCategory);
if (!sipMeth)
return wxEvent::GetEventCategory();
extern wxEventCategory sipVH__core_0(sip_gilstate_t,PyObject *);
return sipVH__core_0(sipGILState,sipMeth);
}
wxClassInfo * sipwxHelpEvent::GetClassInfo()
{
sip_gilstate_t sipGILState;
PyObject *sipMeth;
sipMeth = sipIsPyMethod(&sipGILState,&sipPyMethods[2],sipPySelf,NULL,sipName_GetClassInfo);
if (!sipMeth)
return wxObject::GetClassInfo();
extern wxClassInfo * sipVH__core_6(sip_gilstate_t,PyObject *);
return sipVH__core_6(sipGILState,sipMeth);
}
PyDoc_STRVAR(doc_wxHelpEvent_GetOrigin, "HelpEvent.GetOrigin() -> HelpEvent.Origin");
extern "C" {static PyObject *meth_wxHelpEvent_GetOrigin(PyObject *, PyObject *);}
static PyObject *meth_wxHelpEvent_GetOrigin(PyObject *sipSelf, PyObject *sipArgs)
{
PyObject *sipParseErr = NULL;
{
wxHelpEvent *sipCpp;
if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_wxHelpEvent, &sipCpp))
{
wxHelpEvent::Origin sipRes;
try
{
sipRes = sipCpp->GetOrigin();
}
catch (...)
{
sipRaiseUnknownException();
return NULL;
}
return sipConvertFromEnum(sipRes,sipType_wxHelpEvent_Origin);
}
}
/* Raise an exception if the arguments couldn't be parsed. */
sipNoMethod(sipParseErr, sipName_HelpEvent, sipName_GetOrigin, doc_wxHelpEvent_GetOrigin);
return NULL;
}
PyDoc_STRVAR(doc_wxHelpEvent_GetPosition, "HelpEvent.GetPosition() -> Point");
extern "C" {static PyObject *meth_wxHelpEvent_GetPosition(PyObject *, PyObject *);}
static PyObject *meth_wxHelpEvent_GetPosition(PyObject *sipSelf, PyObject *sipArgs)
{
PyObject *sipParseErr = NULL;
{
wxHelpEvent *sipCpp;
if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_wxHelpEvent, &sipCpp))
{
wxPoint *sipRes;
try
{
sipRes = new wxPoint(sipCpp->GetPosition());
}
catch (...)
{
sipRaiseUnknownException();
return NULL;
}
return sipConvertFromNewType(sipRes,sipType_wxPoint,NULL);
}
}
/* Raise an exception if the arguments couldn't be parsed. */
sipNoMethod(sipParseErr, sipName_HelpEvent, sipName_GetPosition, doc_wxHelpEvent_GetPosition);
return NULL;
}
PyDoc_STRVAR(doc_wxHelpEvent_SetOrigin, "HelpEvent.SetOrigin(HelpEvent.Origin)");
extern "C" {static PyObject *meth_wxHelpEvent_SetOrigin(PyObject *, PyObject *, PyObject *);}
static PyObject *meth_wxHelpEvent_SetOrigin(PyObject *sipSelf, PyObject *sipArgs, PyObject *sipKwds)
{
PyObject *sipParseErr = NULL;
{
wxHelpEvent::Origin origin;
wxHelpEvent *sipCpp;
static const char *sipKwdList[] = {
sipName_origin,
};
if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, NULL, "BE", &sipSelf, sipType_wxHelpEvent, &sipCpp, sipType_wxHelpEvent_Origin, &origin))
{
try
{
sipCpp->SetOrigin(origin);
}
catch (...)
{
sipRaiseUnknownException();
return NULL;
}
Py_INCREF(Py_None);
return Py_None;
}
}
/* Raise an exception if the arguments couldn't be parsed. */
sipNoMethod(sipParseErr, sipName_HelpEvent, sipName_SetOrigin, doc_wxHelpEvent_SetOrigin);
return NULL;
}
PyDoc_STRVAR(doc_wxHelpEvent_SetPosition, "HelpEvent.SetPosition(Point)");
extern "C" {static PyObject *meth_wxHelpEvent_SetPosition(PyObject *, PyObject *, PyObject *);}
static PyObject *meth_wxHelpEvent_SetPosition(PyObject *sipSelf, PyObject *sipArgs, PyObject *sipKwds)
{
PyObject *sipParseErr = NULL;
{
const wxPoint * pt;
int ptState = 0;
wxHelpEvent *sipCpp;
static const char *sipKwdList[] = {
sipName_pt,
};
if (sipParseKwdArgs(&sipParseErr, sipArgs, sipKwds, sipKwdList, NULL, "BJ1", &sipSelf, sipType_wxHelpEvent, &sipCpp, sipType_wxPoint, &pt, &ptState))
{
try
{
sipCpp->SetPosition(*pt);
}
catch (...)
{
sipReleaseType(const_cast<wxPoint *>(pt),sipType_wxPoint,ptState);
sipRaiseUnknownException();
return NULL;
}
sipReleaseType(const_cast<wxPoint *>(pt),sipType_wxPoint,ptState);
Py_INCREF(Py_None);
return Py_None;
}
}
/* Raise an exception if the arguments couldn't be parsed. */
sipNoMethod(sipParseErr, sipName_HelpEvent, sipName_SetPosition, doc_wxHelpEvent_SetPosition);
return NULL;
}
/* Cast a pointer to a type somewhere in its superclass hierarchy. */
extern "C" {static void *cast_wxHelpEvent(void *, const sipTypeDef *);}
static void *cast_wxHelpEvent(void *ptr, const sipTypeDef *targetType)
{
void *res;
if (targetType == sipType_wxHelpEvent)
return ptr;
if ((res = ((const sipClassTypeDef *)sipType_wxCommandEvent)->ctd_cast((wxCommandEvent *)(wxHelpEvent *)ptr,targetType)) != NULL)
return res;
return NULL;
}
/* Call the instance's destructor. */
extern "C" {static void release_wxHelpEvent(void *, int);}
static void release_wxHelpEvent(void *sipCppV,int sipState)
{
if (sipState & SIP_DERIVED_CLASS)
delete reinterpret_cast<sipwxHelpEvent *>(sipCppV);
else
delete reinterpret_cast<wxHelpEvent *>(sipCppV);
}
extern "C" {static void dealloc_wxHelpEvent(sipSimpleWrapper *);}
static void dealloc_wxHelpEvent(sipSimpleWrapper *sipSelf)
{
if (sipIsDerived(sipSelf))
reinterpret_cast<sipwxHelpEvent *>(sipGetAddress(sipSelf))->sipPySelf = NULL;
if (sipIsPyOwned(sipSelf))
{
release_wxHelpEvent(sipGetAddress(sipSelf),sipSelf->flags);
}
}
extern "C" {static void *init_wxHelpEvent(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_wxHelpEvent(sipSimpleWrapper *sipSelf, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
sipwxHelpEvent *sipCpp = 0;
{
wxEventType type = wxEVT_NULL;
wxWindowID winid = 0;
const wxPoint& ptdef = wxDefaultPosition;
const wxPoint * pt = &ptdef;
int ptState = 0;
wxHelpEvent::Origin origin = wxHelpEvent::Origin_Unknown;
static const char *sipKwdList[] = {
sipName_type,
sipName_winid,
sipName_pt,
sipName_origin,
};
if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "|iiJ1E", &type, &winid, sipType_wxPoint, &pt, &ptState, sipType_wxHelpEvent_Origin, &origin))
{
try
{
sipCpp = new sipwxHelpEvent(type,winid,*pt,origin);
}
catch (...)
{
sipReleaseType(const_cast<wxPoint *>(pt),sipType_wxPoint,ptState);
sipRaiseUnknownException();
return NULL;
}
sipReleaseType(const_cast<wxPoint *>(pt),sipType_wxPoint,ptState);
sipCpp->sipPySelf = sipSelf;
return sipCpp;
}
}
{
const wxHelpEvent * a0;
if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, NULL, sipUnused, "J9", sipType_wxHelpEvent, &a0))
{
try
{
sipCpp = new sipwxHelpEvent(*a0);
}
catch (...)
{
sipRaiseUnknownException();
return NULL;
}
sipCpp->sipPySelf = sipSelf;
return sipCpp;
}
}
return NULL;
}
/* Define this type's super-types. */
static sipEncodedTypeDef supers_wxHelpEvent[] = {{9, 255, 1}};
static PyMethodDef methods_wxHelpEvent[] = {
{SIP_MLNAME_CAST(sipName_GetOrigin), meth_wxHelpEvent_GetOrigin, METH_VARARGS, SIP_MLDOC_CAST(doc_wxHelpEvent_GetOrigin)},
{SIP_MLNAME_CAST(sipName_GetPosition), meth_wxHelpEvent_GetPosition, METH_VARARGS, SIP_MLDOC_CAST(doc_wxHelpEvent_GetPosition)},
{SIP_MLNAME_CAST(sipName_SetOrigin), (PyCFunction)meth_wxHelpEvent_SetOrigin, METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_wxHelpEvent_SetOrigin)},
{SIP_MLNAME_CAST(sipName_SetPosition), (PyCFunction)meth_wxHelpEvent_SetPosition, METH_VARARGS|METH_KEYWORDS, SIP_MLDOC_CAST(doc_wxHelpEvent_SetPosition)}
};
static sipEnumMemberDef enummembers_wxHelpEvent[] = {
{sipName_Origin_HelpButton, wxHelpEvent::Origin_HelpButton, 27},
{sipName_Origin_Keyboard, wxHelpEvent::Origin_Keyboard, 27},
{sipName_Origin_Unknown, wxHelpEvent::Origin_Unknown, 27},
};
PyDoc_STRVAR(doc_wxHelpEvent, "\1HelpEvent(int type=wxEVT_NULL, int winid=0, Point pt=wxDefaultPosition, HelpEvent.Origin origin=wxHelpEvent.Origin_Unknown)\n"
"HelpEvent(HelpEvent)");
sipClassTypeDef sipTypeDef__core_wxHelpEvent = {
{
-1,
0,
0,
SIP_TYPE_CLASS,
sipNameNr_wxHelpEvent,
{0}
},
{
sipNameNr_HelpEvent,
{0, 0, 1},
4, methods_wxHelpEvent,
3, enummembers_wxHelpEvent,
0, 0,
{0, 0, 0, 0, 0, 0, 0, 0, 0, 0},
},
doc_wxHelpEvent,
-1,
-1,
supers_wxHelpEvent,
0,
init_wxHelpEvent,
0,
0,
#if PY_MAJOR_VERSION >= 3
0,
0,
#else
0,
0,
0,
0,
#endif
dealloc_wxHelpEvent,
0,
0,
0,
release_wxHelpEvent,
cast_wxHelpEvent,
0,
0,
0
};