/*
 * Interface wrapper code.
 *
 * Generated by SIP 4.19.16
 *
 *     Copyright: (c) 2018 by Total Control Software
 *     License:   wxWindows License
 */

#include "sipAPI_core.h"

        #include <wx/ctrlsub.h>

        #include <wx/window.h>
        #include <wx/event.h>
        #include <wx/gdicmn.h>
        #include <wx/validate.h>
        #include <wx/window.h>
        #include <wx/gdicmn.h>
        #include <wx/dc.h>
        #include <wx/event.h>
        #include <wx/event.h>
    #include <wx/setup.h>
    #include <wxPython/wxpy_api.h>
        #include <wx/event.h>
        #include <wx/cursor.h>
        #include <wx/caret.h>
        #include <wx/layout.h>
        #include <wx/sizer.h>
        #include <wx/dnd.h>
        #include <wx/access.h>
        #include <wx/accel.h>
        #include <wx/menu.h>
        #include <wx/tooltip.h>
        #include <wx/event.h>
        #include <wx/gdicmn.h>
        #include <wx/event.h>
        #include <wx/event.h>
        #include <wx/palette.h>
        #include <wx/colour.h>
        #include <wx/font.h>
        #include <wx/region.h>
        
        #include <wx/eventfilter.h>
        #include <wx/object.h>
        #include <wx/object.h>
        #include <wx/object.h>


/* Cast a pointer to a type somewhere in its inheritance hierarchy. */
extern "C" {static void *cast_wxControlWithItems(void *, const sipTypeDef *);}
static void *cast_wxControlWithItems(void *sipCppV, const sipTypeDef *targetType)
{
     ::wxControlWithItems *sipCpp = reinterpret_cast< ::wxControlWithItems *>(sipCppV);

    if (targetType == sipType_wxControl)
        return static_cast< ::wxControl *>(sipCpp);

    if (targetType == sipType_wxWindow)
        return static_cast< ::wxWindow *>(sipCpp);

    if (targetType == sipType_wxWindowBase)
        return static_cast< ::wxWindowBase *>(sipCpp);

    if (targetType == sipType_wxEvtHandler)
        return static_cast< ::wxEvtHandler *>(sipCpp);

    if (targetType == sipType_wxObject)
        return static_cast< ::wxObject *>(sipCpp);

    if (targetType == sipType_wxTrackable)
        return static_cast< ::wxTrackable *>(sipCpp);

    if (targetType == sipType_wxItemContainer)
        return static_cast< ::wxItemContainer *>(sipCpp);

    if (targetType == sipType_wxItemContainerImmutable)
        return static_cast< ::wxItemContainerImmutable *>(sipCpp);

    return sipCppV;
}


/* Call the instance's destructor. */
extern "C" {static void release_wxControlWithItems(void *, int);}
static void release_wxControlWithItems(void *sipCppV, int)
{
    Py_BEGIN_ALLOW_THREADS

    delete reinterpret_cast< ::wxControlWithItems *>(sipCppV);

    Py_END_ALLOW_THREADS
}


extern "C" {static void dealloc_wxControlWithItems(sipSimpleWrapper *);}
static void dealloc_wxControlWithItems(sipSimpleWrapper *sipSelf)
{
    if (sipIsOwnedByPython(sipSelf))
    {
        release_wxControlWithItems(sipGetAddress(sipSelf), 0);
    }
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_wxControlWithItems[] = {{89, 255, 0}, {269, 255, 1}};

PyDoc_STRVAR(doc_wxControlWithItems, "This is convenience class that derives from both wxControl and\n"
"wxItemContainer.");


sipClassTypeDef sipTypeDef__core_wxControlWithItems = {
    {
        -1,
        SIP_NULLPTR,
        SIP_NULLPTR,
        SIP_TYPE_ABSTRACT|SIP_TYPE_SCC|SIP_TYPE_CLASS,
        sipNameNr_wxControlWithItems,
        {SIP_NULLPTR},
        SIP_NULLPTR
    },
    {
        sipNameNr_ControlWithItems,
        {0, 0, 1},
        0, SIP_NULLPTR,
        0, SIP_NULLPTR,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_wxControlWithItems,
    -1,
    -1,
    supers_wxControlWithItems,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
#if PY_MAJOR_VERSION >= 3
    SIP_NULLPTR,
    SIP_NULLPTR,
#else
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
#endif
    dealloc_wxControlWithItems,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    release_wxControlWithItems,
    cast_wxControlWithItems,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR
};
