/*
 * 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 26 "/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/sipQtGuiQInputEvent.cpp"

#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtGui/qinputdevice.sip"
#include <qinputdevice.h>
#line 33 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQInputEvent.cpp"
#line 25 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qflags.sip"
#include <qglobal.h>
#line 36 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQInputEvent.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 41 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQInputEvent.cpp"
#line 26 "/build/pyqt6/src/pyqt6-6.11.0/sip/QtCore/qcoreevent.sip"
#include <qcoreevent.h>
#line 44 "/build/pyqt6/src/pyqt6-6.11.0/build/QtGui/sipQtGuiQInputEvent.cpp"


PyDoc_STRVAR(doc_QInputEvent_modifiers, "modifiers(self) -> Qt.KeyboardModifier");

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

    {
        const ::QInputEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QInputEvent, &sipCpp))
        {
            ::Qt::KeyboardModifiers*sipRes;

            sipRes = new ::Qt::KeyboardModifiers(sipCpp->modifiers());

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

    sipNoMethod(sipParseErr, sipName_QInputEvent, sipName_modifiers, doc_QInputEvent_modifiers);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QInputEvent_timestamp, "timestamp(self) -> int");

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

    {
        const ::QInputEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QInputEvent, &sipCpp))
        {
            ::quint64 sipRes;

            sipRes = sipCpp->timestamp();

            return PyLong_FromUnsignedLongLong(sipRes);
        }
    }

    sipNoMethod(sipParseErr, sipName_QInputEvent, sipName_timestamp, doc_QInputEvent_timestamp);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QInputEvent_device, "device(self) -> QInputDevice|None");

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

    {
        const ::QInputEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QInputEvent, &sipCpp))
        {
            const ::QInputDevice*sipRes;

            sipRes = sipCpp->device();

            return sipConvertFromType(const_cast< ::QInputDevice *>(sipRes), sipType_QInputDevice, SIP_NULLPTR);
        }
    }

    sipNoMethod(sipParseErr, sipName_QInputEvent, sipName_device, doc_QInputEvent_device);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QInputEvent_deviceType, "deviceType(self) -> QInputDevice.DeviceType");

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

    {
        const ::QInputEvent *sipCpp;

        if (sipParseArgs(&sipParseErr, sipArgs, "B", &sipSelf, sipType_QInputEvent, &sipCpp))
        {
            ::QInputDevice::DeviceType sipRes;

            sipRes = sipCpp->deviceType();

            return sipConvertFromEnum(static_cast<int>(sipRes), sipType_QInputDevice_DeviceType);
        }
    }

    sipNoMethod(sipParseErr, sipName_QInputEvent, sipName_deviceType, doc_QInputEvent_deviceType);

    return SIP_NULLPTR;
}


PyDoc_STRVAR(doc_QInputEvent_clone, "clone(self) -> QInputEvent|None");

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

    {
        const ::QInputEvent *sipCpp;

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

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

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

    sipNoMethod(sipParseErr, sipName_QInputEvent, sipName_clone, doc_QInputEvent_clone);

    return SIP_NULLPTR;
}


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

    if (targetType == sipType_QInputEvent)
        return sipCppV;

    if (targetType == sipType_QEvent)
        return static_cast< ::QEvent *>(sipCpp);

    return SIP_NULLPTR;
}


/* Call the instance's destructor. */
extern "C" {static void release_QInputEvent(void *, int);}
static void release_QInputEvent(void *sipCppV, int)
{
    delete reinterpret_cast< ::QInputEvent *>(sipCppV);
}


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


/* Define this type's super-types. */
static sipEncodedTypeDef supers_QInputEvent[] = {{10, 0, 1}};


static PyMethodDef methods_QInputEvent[] = {
    {sipName_clone, meth_QInputEvent_clone, METH_VARARGS, doc_QInputEvent_clone},
    {sipName_device, meth_QInputEvent_device, METH_VARARGS, doc_QInputEvent_device},
    {sipName_deviceType, meth_QInputEvent_deviceType, METH_VARARGS, doc_QInputEvent_deviceType},
    {sipName_modifiers, meth_QInputEvent_modifiers, METH_VARARGS, doc_QInputEvent_modifiers},
    {sipName_timestamp, meth_QInputEvent_timestamp, METH_VARARGS, doc_QInputEvent_timestamp}
};


sipClassTypeDef sipTypeDef_QtGui_QInputEvent = {
    {
        SIP_NULLPTR,
        SIP_TYPE_SCC|SIP_TYPE_SUPER_INIT|SIP_TYPE_LIMITED_API|SIP_TYPE_CLASS,
        sipNameNr_QInputEvent,
        SIP_NULLPTR,
        SIP_NULLPTR,
    },
    {
        sipNameNr_QInputEvent,
        {0, 0, 1},
        5, methods_QInputEvent,
        0, SIP_NULLPTR,
        {SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR, SIP_NULLPTR},
    },
    SIP_NULLPTR,
    -1,
    -1,
    supers_QInputEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    dealloc_QInputEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    release_QInputEvent,
    cast_QInputEvent,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    SIP_NULLPTR,
    0,
};
