PythonQtWrapper_QMovie.cpp
262 lines
| 7.9 KiB
| text/x-c
|
CppLexer
florianlink
|
r13 | #include "PythonQtWrapper_QMovie.h" | ||
florianlink
|
r24 | #include <PythonQtSignalReceiver.h> | ||
#include <PythonQtMethodInfo.h> | ||||
#include <PythonQtConversion.h> | ||||
florianlink
|
r13 | #include <QColor> | ||
#include <QImage> | ||||
#include <QPixmap> | ||||
#include <QRect> | ||||
#include <QSize> | ||||
#include <QVariant> | ||||
#include <qbytearray.h> | ||||
#include <qcolor.h> | ||||
#include <qcoreevent.h> | ||||
#include <qimage.h> | ||||
#include <qiodevice.h> | ||||
#include <qlist.h> | ||||
#include <qmovie.h> | ||||
#include <qobject.h> | ||||
#include <qpixmap.h> | ||||
#include <qrect.h> | ||||
#include <qsize.h> | ||||
florianlink
|
r24 | void PythonQtShell_QMovie::childEvent(QChildEvent* arg__1) | ||
{ | ||||
if (_wrapper) { | ||||
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "childEvent"); | ||||
PyErr_Clear(); | ||||
if (obj && !PythonQtSlotFunction_Check(obj)) { | ||||
florianlink
|
r73 | static const char* argumentList[] ={"" , "QChildEvent*"}; | ||
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList); | ||||
florianlink
|
r24 | void* args[2] = {NULL, (void*)&arg__1}; | ||
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true); | ||||
if (result) { Py_DECREF(result); } | ||||
Py_DECREF(obj); | ||||
return; | ||||
} | ||||
} | ||||
QMovie::childEvent(arg__1); | ||||
} | ||||
void PythonQtShell_QMovie::customEvent(QEvent* arg__1) | ||||
{ | ||||
if (_wrapper) { | ||||
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "customEvent"); | ||||
PyErr_Clear(); | ||||
if (obj && !PythonQtSlotFunction_Check(obj)) { | ||||
florianlink
|
r73 | static const char* argumentList[] ={"" , "QEvent*"}; | ||
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList); | ||||
florianlink
|
r24 | void* args[2] = {NULL, (void*)&arg__1}; | ||
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true); | ||||
if (result) { Py_DECREF(result); } | ||||
Py_DECREF(obj); | ||||
return; | ||||
} | ||||
} | ||||
QMovie::customEvent(arg__1); | ||||
} | ||||
bool PythonQtShell_QMovie::event(QEvent* arg__1) | ||||
{ | ||||
if (_wrapper) { | ||||
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "event"); | ||||
PyErr_Clear(); | ||||
if (obj && !PythonQtSlotFunction_Check(obj)) { | ||||
florianlink
|
r73 | static const char* argumentList[] ={"bool" , "QEvent*"}; | ||
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList); | ||||
bool returnValue; | ||||
florianlink
|
r24 | void* args[2] = {NULL, (void*)&arg__1}; | ||
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true); | ||||
if (result) { | ||||
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue); | ||||
if (args[0]!=&returnValue) { | ||||
florianlink
|
r73 | if (args[0]==NULL) { | ||
PythonQt::priv()->handleVirtualOverloadReturnError("event", methodInfo, result); | ||||
} else { | ||||
returnValue = *((bool*)args[0]); | ||||
} | ||||
florianlink
|
r24 | } | ||
} | ||||
if (result) { Py_DECREF(result); } | ||||
Py_DECREF(obj); | ||||
return returnValue; | ||||
} | ||||
} | ||||
return QMovie::event(arg__1); | ||||
} | ||||
bool PythonQtShell_QMovie::eventFilter(QObject* arg__1, QEvent* arg__2) | ||||
{ | ||||
if (_wrapper) { | ||||
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "eventFilter"); | ||||
PyErr_Clear(); | ||||
if (obj && !PythonQtSlotFunction_Check(obj)) { | ||||
florianlink
|
r73 | static const char* argumentList[] ={"bool" , "QObject*" , "QEvent*"}; | ||
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(3, argumentList); | ||||
bool returnValue; | ||||
florianlink
|
r24 | void* args[3] = {NULL, (void*)&arg__1, (void*)&arg__2}; | ||
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true); | ||||
if (result) { | ||||
args[0] = PythonQtConv::ConvertPythonToQt(methodInfo->parameters().at(0), result, false, NULL, &returnValue); | ||||
if (args[0]!=&returnValue) { | ||||
florianlink
|
r73 | if (args[0]==NULL) { | ||
PythonQt::priv()->handleVirtualOverloadReturnError("eventFilter", methodInfo, result); | ||||
} else { | ||||
returnValue = *((bool*)args[0]); | ||||
} | ||||
florianlink
|
r24 | } | ||
} | ||||
if (result) { Py_DECREF(result); } | ||||
Py_DECREF(obj); | ||||
return returnValue; | ||||
} | ||||
} | ||||
return QMovie::eventFilter(arg__1, arg__2); | ||||
} | ||||
void PythonQtShell_QMovie::timerEvent(QTimerEvent* arg__1) | ||||
{ | ||||
if (_wrapper) { | ||||
PyObject* obj = PyObject_GetAttrString((PyObject*)_wrapper, "timerEvent"); | ||||
PyErr_Clear(); | ||||
if (obj && !PythonQtSlotFunction_Check(obj)) { | ||||
florianlink
|
r73 | static const char* argumentList[] ={"" , "QTimerEvent*"}; | ||
static const PythonQtMethodInfo* methodInfo = PythonQtMethodInfo::getCachedMethodInfoFromArgumentList(2, argumentList); | ||||
florianlink
|
r24 | void* args[2] = {NULL, (void*)&arg__1}; | ||
PyObject* result = PythonQtSignalTarget::call(obj, methodInfo, args, true); | ||||
if (result) { Py_DECREF(result); } | ||||
Py_DECREF(obj); | ||||
return; | ||||
} | ||||
} | ||||
QMovie::timerEvent(arg__1); | ||||
} | ||||
florianlink
|
r13 | QMovie* PythonQtWrapper_QMovie::new_QMovie(QIODevice* device, const QByteArray& format, QObject* parent) | ||
{ | ||||
florianlink
|
r24 | return new PythonQtShell_QMovie(device, format, parent); } | ||
florianlink
|
r13 | |||
QMovie* PythonQtWrapper_QMovie::new_QMovie(QObject* parent) | ||||
{ | ||||
florianlink
|
r24 | return new PythonQtShell_QMovie(parent); } | ||
florianlink
|
r13 | |||
QMovie* PythonQtWrapper_QMovie::new_QMovie(const QString& fileName, const QByteArray& format, QObject* parent) | ||||
{ | ||||
florianlink
|
r24 | return new PythonQtShell_QMovie(fileName, format, parent); } | ||
florianlink
|
r13 | |||
florianlink
|
r73 | void PythonQtWrapper_QMovie::setDevice(QMovie* theWrappedObject, QIODevice* device) | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | ( theWrappedObject->setDevice(device)); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | QMovie::MovieState PythonQtWrapper_QMovie::state(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->state()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | int PythonQtWrapper_QMovie::speed(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->speed()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | int PythonQtWrapper_QMovie::loopCount(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->loopCount()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | void PythonQtWrapper_QMovie::setFileName(QMovie* theWrappedObject, const QString& fileName) | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | ( theWrappedObject->setFileName(fileName)); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | QList<QByteArray > PythonQtWrapper_QMovie::static_QMovie_supportedFormats() | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return (QMovie::supportedFormats()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | QMovie::CacheMode PythonQtWrapper_QMovie::cacheMode(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->cacheMode()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | int PythonQtWrapper_QMovie::currentFrameNumber(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->currentFrameNumber()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | void PythonQtWrapper_QMovie::setScaledSize(QMovie* theWrappedObject, const QSize& size) | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | ( theWrappedObject->setScaledSize(size)); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | void PythonQtWrapper_QMovie::setBackgroundColor(QMovie* theWrappedObject, const QColor& color) | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | ( theWrappedObject->setBackgroundColor(color)); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | void PythonQtWrapper_QMovie::setFormat(QMovie* theWrappedObject, const QByteArray& format) | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | ( theWrappedObject->setFormat(format)); | ||
florianlink
|
r13 | } | ||
florianlink
|
r24 | int PythonQtWrapper_QMovie::nextFrameDelay(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->nextFrameDelay()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | QImage PythonQtWrapper_QMovie::currentImage(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->currentImage()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r24 | QString PythonQtWrapper_QMovie::fileName(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->fileName()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r24 | bool PythonQtWrapper_QMovie::isValid(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->isValid()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | void PythonQtWrapper_QMovie::setCacheMode(QMovie* theWrappedObject, QMovie::CacheMode mode) | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | ( theWrappedObject->setCacheMode(mode)); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | QSize PythonQtWrapper_QMovie::scaledSize(QMovie* theWrappedObject) | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->scaledSize()); | ||
florianlink
|
r28 | } | ||
florianlink
|
r73 | int PythonQtWrapper_QMovie::frameCount(QMovie* theWrappedObject) const | ||
florianlink
|
r28 | { | ||
florianlink
|
r73 | return ( theWrappedObject->frameCount()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | QColor PythonQtWrapper_QMovie::backgroundColor(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->backgroundColor()); | ||
florianlink
|
r13 | } | ||
florianlink
|
r73 | QRect PythonQtWrapper_QMovie::frameRect(QMovie* theWrappedObject) const | ||
florianlink
|
r13 | { | ||
florianlink
|
r73 | return ( theWrappedObject->frameRect()); | ||
florianlink
|
r28 | } | ||
florianlink
|
r73 | QPixmap PythonQtWrapper_QMovie::currentPixmap(QMovie* theWrappedObject) const | ||
florianlink
|
r28 | { | ||
florianlink
|
r73 | return ( theWrappedObject->currentPixmap()); | ||
florianlink
|
r28 | } | ||
florianlink
|
r73 | QByteArray PythonQtWrapper_QMovie::format(QMovie* theWrappedObject) const | ||
florianlink
|
r28 | { | ||
florianlink
|
r73 | return ( theWrappedObject->format()); | ||
florianlink
|
r28 | } | ||
florianlink
|
r73 | QIODevice* PythonQtWrapper_QMovie::device(QMovie* theWrappedObject) const | ||
{ | ||||
return ( theWrappedObject->device()); | ||||
} | ||||
bool PythonQtWrapper_QMovie::jumpToFrame(QMovie* theWrappedObject, int frameNumber) | ||||
florianlink
|
r28 | { | ||
florianlink
|
r73 | return ( theWrappedObject->jumpToFrame(frameNumber)); | ||
florianlink
|
r13 | } | ||