miqt/qt/gen_qabstractanimation.cpp

290 lines
9.9 KiB
C++
Raw Normal View History

#include <QAbstractAnimation>
#include <QAnimationDriver>
#include <QAnimationGroup>
#include <QMetaObject>
#include <QObject>
#include <QString>
2024-08-29 07:01:51 +00:00
#include <QByteArray>
#include <cstring>
#include "qabstractanimation.h"
#include "gen_qabstractanimation.h"
#include "_cgo_export.h"
QMetaObject* QAbstractAnimation_MetaObject(const QAbstractAnimation* self) {
return (QMetaObject*) self->metaObject();
}
struct miqt_string* QAbstractAnimation_Tr(const char* s) {
QString _ret = QAbstractAnimation::tr(s);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAbstractAnimation_TrUtf8(const char* s) {
QString _ret = QAbstractAnimation::trUtf8(s);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
uintptr_t QAbstractAnimation_State(const QAbstractAnimation* self) {
QAbstractAnimation::State _ret = self->state();
return static_cast<uintptr_t>(_ret);
2024-08-29 07:01:51 +00:00
}
QAnimationGroup* QAbstractAnimation_Group(const QAbstractAnimation* self) {
return self->group();
2024-08-29 07:01:51 +00:00
}
uintptr_t QAbstractAnimation_Direction(const QAbstractAnimation* self) {
QAbstractAnimation::Direction _ret = self->direction();
return static_cast<uintptr_t>(_ret);
2024-08-29 07:01:51 +00:00
}
void QAbstractAnimation_SetDirection(QAbstractAnimation* self, uintptr_t direction) {
self->setDirection(static_cast<QAbstractAnimation::Direction>(direction));
}
int QAbstractAnimation_CurrentTime(const QAbstractAnimation* self) {
return self->currentTime();
}
int QAbstractAnimation_CurrentLoopTime(const QAbstractAnimation* self) {
return self->currentLoopTime();
}
int QAbstractAnimation_LoopCount(const QAbstractAnimation* self) {
return self->loopCount();
}
void QAbstractAnimation_SetLoopCount(QAbstractAnimation* self, int loopCount) {
self->setLoopCount(static_cast<int>(loopCount));
}
int QAbstractAnimation_CurrentLoop(const QAbstractAnimation* self) {
return self->currentLoop();
}
int QAbstractAnimation_Duration(const QAbstractAnimation* self) {
return self->duration();
}
int QAbstractAnimation_TotalDuration(const QAbstractAnimation* self) {
return self->totalDuration();
}
void QAbstractAnimation_Finished(QAbstractAnimation* self) {
self->finished();
}
void QAbstractAnimation_connect_Finished(QAbstractAnimation* self, void* slot) {
QAbstractAnimation::connect(self, static_cast<void (QAbstractAnimation::*)()>(&QAbstractAnimation::finished), self, [=]() {
miqt_exec_callback_QAbstractAnimation_Finished(slot);
});
}
2024-08-29 07:01:51 +00:00
void QAbstractAnimation_StateChanged(QAbstractAnimation* self, uintptr_t newState, uintptr_t oldState) {
self->stateChanged(static_cast<QAbstractAnimation::State>(newState), static_cast<QAbstractAnimation::State>(oldState));
}
void QAbstractAnimation_connect_StateChanged(QAbstractAnimation* self, void* slot) {
QAbstractAnimation::connect(self, static_cast<void (QAbstractAnimation::*)(QAbstractAnimation::State, QAbstractAnimation::State)>(&QAbstractAnimation::stateChanged), self, [=](QAbstractAnimation::State newState, QAbstractAnimation::State oldState) {
QAbstractAnimation::State newState_ret = newState;
uintptr_t sigval1 = static_cast<uintptr_t>(newState_ret);
QAbstractAnimation::State oldState_ret = oldState;
uintptr_t sigval2 = static_cast<uintptr_t>(oldState_ret);
miqt_exec_callback_QAbstractAnimation_StateChanged(slot, sigval1, sigval2);
2024-08-29 07:01:51 +00:00
});
}
void QAbstractAnimation_CurrentLoopChanged(QAbstractAnimation* self, int currentLoop) {
self->currentLoopChanged(static_cast<int>(currentLoop));
}
void QAbstractAnimation_connect_CurrentLoopChanged(QAbstractAnimation* self, void* slot) {
QAbstractAnimation::connect(self, static_cast<void (QAbstractAnimation::*)(int)>(&QAbstractAnimation::currentLoopChanged), self, [=](int currentLoop) {
int sigval1 = currentLoop;
miqt_exec_callback_QAbstractAnimation_CurrentLoopChanged(slot, sigval1);
});
}
2024-08-29 07:01:51 +00:00
void QAbstractAnimation_DirectionChanged(QAbstractAnimation* self, uintptr_t param1) {
self->directionChanged(static_cast<QAbstractAnimation::Direction>(param1));
}
void QAbstractAnimation_connect_DirectionChanged(QAbstractAnimation* self, void* slot) {
QAbstractAnimation::connect(self, static_cast<void (QAbstractAnimation::*)(QAbstractAnimation::Direction)>(&QAbstractAnimation::directionChanged), self, [=](QAbstractAnimation::Direction param1) {
QAbstractAnimation::Direction param1_ret = param1;
uintptr_t sigval1 = static_cast<uintptr_t>(param1_ret);
miqt_exec_callback_QAbstractAnimation_DirectionChanged(slot, sigval1);
2024-08-29 07:01:51 +00:00
});
}
void QAbstractAnimation_Start(QAbstractAnimation* self) {
self->start();
}
void QAbstractAnimation_Pause(QAbstractAnimation* self) {
self->pause();
}
void QAbstractAnimation_Resume(QAbstractAnimation* self) {
self->resume();
}
void QAbstractAnimation_SetPaused(QAbstractAnimation* self, bool paused) {
self->setPaused(paused);
}
void QAbstractAnimation_Stop(QAbstractAnimation* self) {
self->stop();
}
void QAbstractAnimation_SetCurrentTime(QAbstractAnimation* self, int msecs) {
self->setCurrentTime(static_cast<int>(msecs));
}
struct miqt_string* QAbstractAnimation_Tr2(const char* s, const char* c) {
QString _ret = QAbstractAnimation::tr(s, c);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAbstractAnimation_Tr3(const char* s, const char* c, int n) {
QString _ret = QAbstractAnimation::tr(s, c, static_cast<int>(n));
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAbstractAnimation_TrUtf82(const char* s, const char* c) {
QString _ret = QAbstractAnimation::trUtf8(s, c);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAbstractAnimation_TrUtf83(const char* s, const char* c, int n) {
QString _ret = QAbstractAnimation::trUtf8(s, c, static_cast<int>(n));
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
2024-08-29 07:01:51 +00:00
void QAbstractAnimation_Start1(QAbstractAnimation* self, uintptr_t policy) {
self->start(static_cast<QAbstractAnimation::DeletionPolicy>(policy));
}
void QAbstractAnimation_Delete(QAbstractAnimation* self) {
delete self;
}
QAnimationDriver* QAnimationDriver_new() {
return new QAnimationDriver();
}
QAnimationDriver* QAnimationDriver_new2(QObject* parent) {
return new QAnimationDriver(parent);
}
QMetaObject* QAnimationDriver_MetaObject(const QAnimationDriver* self) {
return (QMetaObject*) self->metaObject();
}
struct miqt_string* QAnimationDriver_Tr(const char* s) {
QString _ret = QAnimationDriver::tr(s);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAnimationDriver_TrUtf8(const char* s) {
QString _ret = QAnimationDriver::trUtf8(s);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
void QAnimationDriver_Advance(QAnimationDriver* self) {
self->advance();
}
void QAnimationDriver_Install(QAnimationDriver* self) {
self->install();
}
void QAnimationDriver_Uninstall(QAnimationDriver* self) {
self->uninstall();
}
bool QAnimationDriver_IsRunning(const QAnimationDriver* self) {
return self->isRunning();
}
long long QAnimationDriver_Elapsed(const QAnimationDriver* self) {
return self->elapsed();
}
2024-08-29 07:01:51 +00:00
void QAnimationDriver_SetStartTime(QAnimationDriver* self, long long startTime) {
self->setStartTime(static_cast<qint64>(startTime));
}
long long QAnimationDriver_StartTime(const QAnimationDriver* self) {
return self->startTime();
}
void QAnimationDriver_Started(QAnimationDriver* self) {
self->started();
}
void QAnimationDriver_connect_Started(QAnimationDriver* self, void* slot) {
QAnimationDriver::connect(self, static_cast<void (QAnimationDriver::*)()>(&QAnimationDriver::started), self, [=]() {
miqt_exec_callback_QAnimationDriver_Started(slot);
});
}
void QAnimationDriver_Stopped(QAnimationDriver* self) {
self->stopped();
}
void QAnimationDriver_connect_Stopped(QAnimationDriver* self, void* slot) {
QAnimationDriver::connect(self, static_cast<void (QAnimationDriver::*)()>(&QAnimationDriver::stopped), self, [=]() {
miqt_exec_callback_QAnimationDriver_Stopped(slot);
});
}
struct miqt_string* QAnimationDriver_Tr2(const char* s, const char* c) {
QString _ret = QAnimationDriver::tr(s, c);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAnimationDriver_Tr3(const char* s, const char* c, int n) {
QString _ret = QAnimationDriver::tr(s, c, static_cast<int>(n));
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAnimationDriver_TrUtf82(const char* s, const char* c) {
QString _ret = QAnimationDriver::trUtf8(s, c);
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
struct miqt_string* QAnimationDriver_TrUtf83(const char* s, const char* c, int n) {
QString _ret = QAnimationDriver::trUtf8(s, c, static_cast<int>(n));
// Convert QString from UTF-16 in C++ RAII memory to UTF-8 in manually-managed C memory
QByteArray _b = _ret.toUtf8();
return miqt_strdup(_b.data(), _b.length());
}
void QAnimationDriver_Delete(QAnimationDriver* self) {
delete self;
}