/*
 * Interface wrapper code.
 *
 * Generated by SIP 6.15.3
 *
 * Copyright (c) 2026 Riverbank Computing Limited <info@riverbankcomputing.com>
 * 
 * This file is part of PyQt6.
 * 
 * This file may be used under the terms of the GNU General Public License
 * version 3.0 as published by the Free Software Foundation and appearing in
 * the file LICENSE included in the packaging of this file.  Please review the
 * following information to ensure the GNU General Public License version 3.0
 * requirements will be met: http://www.gnu.org/copyleft/gpl.html.
 * 
 * If you do not wish to use this file under the terms of the GPL version 3.0
 * then you may purchase a commercial license.  For more information contact
 * info@riverbankcomputing.com.
 * 
 * This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
 * WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
 */

#include "sipAPIQtGui.h"

#line 848 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qevent.sip"
#include <qevent.h>
#line 29 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"

#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 33 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 46 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qpointingdevice.sip"
#include <qpointingdevice.h>
#line 36 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 25 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qflags.sip"
#include <qglobal.h>
#line 39 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qnamespace.sip"
#include <qnamespace.h>
#line 154 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qtextstream.sip"
#include <qtextstream.h>
#line 44 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 28 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qpycore_qlist.sip"
#include <qlist.h>
#line 47 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qeventpoint.sip"
#include <qeventpoint.h>
#line 50 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 25 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qflags.sip"
#include <qglobal.h>
#line 53 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 28 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qobject.sip"
#include <qobject.h>
#line 56 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qinputdevice.sip"
#include <qinputdevice.h>
#line 59 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQTouchEvent.cpp"


class sipQTouchEvent : public ::QTouchEvent
{
public:
    sipQTouchEvent(::QEvent::Type, const ::QPointingDevice*, ::Qt::KeyboardModifiers, const QList< ::QEventPoint>&);
    virtual ~sipQTouchEvent();

    /*
     * There is a protected method for every virtual method visible from
     * this class.
     */
protected:
    void setAccepted(bool) SIP_OVERRIDE;
    ::QTouchEvent* clone() const SIP_OVERRIDE;
    bool isBeginEvent() const SIP_OVERRIDE;
    bool isUpdateEvent() const SIP_OVERRIDE;
    bool isEndEvent() const SIP_OVERRIDE;

public:
    sipSimpleWrapper *sipPySelf;

private:
    sipQTouchEvent(const sipQTouchEvent &);
    sipQTouchEvent &operator = (const sipQTouchEvent &);

    char sipPyMethods[5];
};

sipQTouchEvent::sipQTouchEvent(::QEvent::Type a0, const ::QPointingDevice*a1, ::Qt::KeyboardModifiers a2, const QList< ::QEventPoint>& a3): ::QTouchEvent(a0, a1, a2, a3), sipPySelf(SIP_NULLPTR)
{
    memset(sipPyMethods, 0, sizeof (sipPyMethods));
}

sipQTouchEvent::~sipQTouchEvent()
{
    sipInstanceDestroyedEx(&sipPySelf);
}

void sipQTouchEvent::setAccepted(bool a0)
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, &sipPyMethods[0], &sipPySelf, SIP_NULLPTR, sipName_setAccepted);

    if (!sipMeth)
    {
        ::QTouchEvent::setAccepted(a0);
        return;
    }

    extern void sipVH_QtGui_25(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *, bool);

    sipVH_QtGui_25(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth, a0);
}

::QTouchEvent* sipQTouchEvent::clone() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[1]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_clone);

    if (!sipMeth)
        return ::QTouchEvent::clone();

    extern ::QTouchEvent* sipVH_QtGui_62(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtGui_62(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth);
}

bool sipQTouchEvent::isBeginEvent() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[2]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_isBeginEvent);

    if (!sipMeth)
        return ::QTouchEvent::isBeginEvent();

    extern bool sipVH_QtGui_54(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtGui_54(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth);
}

bool sipQTouchEvent::isUpdateEvent() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[3]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_isUpdateEvent);

    if (!sipMeth)
        return ::QTouchEvent::isUpdateEvent();

    extern bool sipVH_QtGui_54(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtGui_54(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth);
}

bool sipQTouchEvent::isEndEvent() const
{
    sip_gilstate_t sipGILState;
    PyObject *sipMeth;

    sipMeth = sipIsPyMethod(&sipGILState, const_cast<char *>(&sipPyMethods[4]), const_cast<sipSimpleWrapper **>(&sipPySelf), SIP_NULLPTR, sipName_isEndEvent);

    if (!sipMeth)
        return ::QTouchEvent::isEndEvent();

    extern bool sipVH_QtGui_54(sip_gilstate_t, sipVirtErrorHandlerFunc, sipSimpleWrapper *, PyObject *);

    return sipVH_QtGui_54(sipGILState, sipImportedVirtErrorHandlers_QtGui_QtCore[0].iveh_handler, sipPySelf, sipMeth);
}


PyDoc_STRVAR(doc_QTouchEvent_target, "target(self) -> QObject|None");

extern "C" {static PyObject *meth_QTouchEvent_target(PyObject *, PyObject *);}
static PyObject *meth_QTouchEvent_target(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTouchEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTouchEvent, &sipCpp))
        {
            ::QObject*sipRes;

            sipRes = sipCpp->target();

            return sipConvertFromType(sipRes, sipType_QObject, SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTouchEvent, sipName_target, doc_QTouchEvent_target);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTouchEvent_touchPointStates, "touchPointStates(self) -> QEventPoint.State");

extern "C" {static PyObject *meth_QTouchEvent_touchPointStates(PyObject *, PyObject *);}
static PyObject *meth_QTouchEvent_touchPointStates(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;

    {
        const ::QTouchEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTouchEvent, &sipCpp))
        {
            ::QEventPoint::States*sipRes;

            sipRes = new ::QEventPoint::States(sipCpp->touchPointStates());

            return sipConvertFromNewType(sipRes, sipType_QFlags_0100QEventPoint_State, SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTouchEvent, sipName_touchPointStates, doc_QTouchEvent_touchPointStates);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTouchEvent_isBeginEvent, "isBeginEvent(self) -> bool");

extern "C" {static PyObject *meth_QTouchEvent_isBeginEvent(PyObject *, PyObject *);}
static PyObject *meth_QTouchEvent_isBeginEvent(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_QTouchEvent)) || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const ::QTouchEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTouchEvent, &sipCpp))
        {
            bool sipRes;

            sipRes = (sipSelfWasArg ? sipCpp->::QTouchEvent::isBeginEvent() : sipCpp->isBeginEvent());

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTouchEvent, sipName_isBeginEvent, doc_QTouchEvent_isBeginEvent);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTouchEvent_isUpdateEvent, "isUpdateEvent(self) -> bool");

extern "C" {static PyObject *meth_QTouchEvent_isUpdateEvent(PyObject *, PyObject *);}
static PyObject *meth_QTouchEvent_isUpdateEvent(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_QTouchEvent)) || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const ::QTouchEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTouchEvent, &sipCpp))
        {
            bool sipRes;

            sipRes = (sipSelfWasArg ? sipCpp->::QTouchEvent::isUpdateEvent() : sipCpp->isUpdateEvent());

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTouchEvent, sipName_isUpdateEvent, doc_QTouchEvent_isUpdateEvent);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTouchEvent_isEndEvent, "isEndEvent(self) -> bool");

extern "C" {static PyObject *meth_QTouchEvent_isEndEvent(PyObject *, PyObject *);}
static PyObject *meth_QTouchEvent_isEndEvent(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_QTouchEvent)) || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const ::QTouchEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTouchEvent, &sipCpp))
        {
            bool sipRes;

            sipRes = (sipSelfWasArg ? sipCpp->::QTouchEvent::isEndEvent() : sipCpp->isEndEvent());

            return PyBool_FromLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTouchEvent, sipName_isEndEvent, doc_QTouchEvent_isEndEvent);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QTouchEvent_clone, "clone(self) -> QTouchEvent|None");

extern "C" {static PyObject *meth_QTouchEvent_clone(PyObject *, PyObject *);}
static PyObject *meth_QTouchEvent_clone(PyObject *sipSelf, PyObject *sipArgs)
{
    PyObject *sipParseErr = SIP_NULLPTR;
    bool sipSelfWasArg = (!PyObject_TypeCheck(sipSelf, sipTypeAsPyTypeObject(sipType_QTouchEvent)) || sipIsDerivedClass((sipSimpleWrapper *)sipSelf));

    {
        const ::QTouchEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QTouchEvent, &sipCpp))
        {
            ::QTouchEvent*sipRes;

            sipRes = (sipSelfWasArg ? sipCpp->::QTouchEvent::clone() : sipCpp->clone());

            return sipConvertFromType(sipRes, sipType_QTouchEvent, Py_None);
        }
    }

    sipNoMethod(sipParseErr, sipName_QTouchEvent, sipName_clone, doc_QTouchEvent_clone);

    return SIP_NULLPTR;
}


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

    if (targetType == sipType_QTouchEvent)
        return sipCppV;

    sipCppV = ((const sipClassTypeDef *)sipType_QPointerEvent)->ctd_cast(static_cast< ::QPointerEvent *>(sipCpp), targetType);
    if (sipCppV)
        return sipCppV;

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QTouchEvent(void *, int);}
static void release_QTouchEvent(void *sipCppV, int sipState)
{
    if (sipState & SIP_DERIVED_CLASS)
        delete reinterpret_cast<sipQTouchEvent *>(sipCppV);
    else
        delete reinterpret_cast< ::QTouchEvent *>(sipCppV);
}


extern "C" {static void dealloc_QTouchEvent(sipSimpleWrapper *);}
static void dealloc_QTouchEvent(sipSimpleWrapper *sipSelf)
{
    if (sipIsDerivedClass(sipSelf))
        reinterpret_cast<sipQTouchEvent *>(sipGetAddress(sipSelf))->sipPySelf = SIP_NULLPTR;

    if (sipIsOwnedByPython(sipSelf))
    {
        release_QTouchEvent(sipGetAddress(sipSelf), sipIsDerivedClass(sipSelf));
    }
}


extern "C" {static void *init_type_QTouchEvent(sipSimpleWrapper *, PyObject *, PyObject *, PyObject **, PyObject **, PyObject **);}
static void *init_type_QTouchEvent(sipSimpleWrapper *sipSelf, PyObject *sipArgs, PyObject *sipKwds, PyObject **sipUnused, PyObject **, PyObject **sipParseErr)
{
    sipQTouchEvent *sipCpp = SIP_NULLPTR;

    {
        ::QEvent::Type a0;
        const ::QPointingDevice* a1 = 0;
        ::Qt::KeyboardModifiers a2def = Qt::NoModifier;
        ::Qt::KeyboardModifiers* a2 = &a2def;
        int a2State = 0;
        const QList< ::QEventPoint>& a3def = {};
        const QList< ::QEventPoint>* a3 = &a3def;
        int a3State = 0;

        static const char *sipKwdList[] = {
            SIP_NULLPTR,
            sipName_device,
            sipName_modifiers,
            sipName_touchPoints,
        };

        if (sipParseKwdArgs(sipParseErr, sipArgs, sipKwds, sipKwdList, sipUnused, "E|J8J1J1", sipType_QEvent_Type, &a0, sipType_QPointingDevice, &a1, sipType_QFlags_0100Qt_KeyboardModifier, &a2, &a2State, sipType_QList_0100QEventPoint, &a3, &a3State))
        {
            sipCpp = new sipQTouchEvent(a0, a1, *a2, *a3);
            sipReleaseType(a2, sipType_QFlags_0100Qt_KeyboardModifier, a2State);
            sipReleaseType(const_cast<QList< ::QEventPoint> *>(a3), sipType_QList_0100QEventPoint, a3State);

            sipCpp->sipPySelf = sipSelf;

            return sipCpp;
        }
    }

    return SIP_NULLPTR;
}


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QTouchEvent[] = {{245, 255, 1}};


static PyMethodDef methods_QTouchEvent[] = {
    {sipName_clone, meth_QTouchEvent_clone, METH_VARARGS, doc_QTouchEvent_clone},
    {sipName_isBeginEvent, meth_QTouchEvent_isBeginEvent, METH_VARARGS, doc_QTouchEvent_isBeginEvent},
    {sipName_isEndEvent, meth_QTouchEvent_isEndEvent, METH_VARARGS, doc_QTouchEvent_isEndEvent},
    {sipName_isUpdateEvent, meth_QTouchEvent_isUpdateEvent, METH_VARARGS, doc_QTouchEvent_isUpdateEvent},
    {sipName_target, meth_QTouchEvent_target, METH_VARARGS, doc_QTouchEvent_target},
    {sipName_touchPointStates, meth_QTouchEvent_touchPointStates, METH_VARARGS, doc_QTouchEvent_touchPointStates}
};

PyDoc_STRVAR(doc_QTouchEvent, "\1QTouchEvent(eventType: QEvent.Type, device: QPointingDevice|None = None, modifiers: Qt.KeyboardModifier = Qt.NoModifier, touchPoints: Iterable[QEventPoint] = [])");


sipClassTypeDef sipTypeDef_QtGui_QTouchEvent = {
    {
        SIP_NULLPTR,
        SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QTouchEvent,
        SIP_NULLPTR,
        SIP_NULLPTR,
    },
    {
        sipNameNr_QTouchEvent,
        {0, 0, 1},
        6, methods_QTouchEvent,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    doc_QTouchEvent,
    -1,
    -1,
    supers_QTouchEvent,
    SIP_NULLPTR,
    init_type_QTouchEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QTouchEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    release_QTouchEvent,
    cast_QTouchEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    sizeof (::QTouchEvent),
};
