2024-08-25 04:08:24 +00:00
|
|
|
#ifndef GEN_QTHREAD_H
|
|
|
|
#define GEN_QTHREAD_H
|
|
|
|
|
|
|
|
#include <stdbool.h>
|
|
|
|
#include <stddef.h>
|
|
|
|
#include <stdint.h>
|
|
|
|
|
|
|
|
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
|
|
|
|
|
2024-09-14 22:29:05 +00:00
|
|
|
#include "binding.h"
|
|
|
|
|
2024-08-25 04:08:24 +00:00
|
|
|
#ifdef __cplusplus
|
|
|
|
extern "C" {
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
class QAbstractEventDispatcher;
|
|
|
|
class QDeadlineTimer;
|
|
|
|
class QEvent;
|
|
|
|
class QMetaObject;
|
|
|
|
class QObject;
|
|
|
|
class QThread;
|
|
|
|
#else
|
|
|
|
typedef struct QAbstractEventDispatcher QAbstractEventDispatcher;
|
|
|
|
typedef struct QDeadlineTimer QDeadlineTimer;
|
|
|
|
typedef struct QEvent QEvent;
|
|
|
|
typedef struct QMetaObject QMetaObject;
|
|
|
|
typedef struct QObject QObject;
|
|
|
|
typedef struct QThread QThread;
|
|
|
|
#endif
|
|
|
|
|
|
|
|
QThread* QThread_new();
|
|
|
|
QThread* QThread_new2(QObject* parent);
|
2024-09-11 05:41:09 +00:00
|
|
|
QMetaObject* QThread_MetaObject(const QThread* self);
|
2024-09-20 22:32:57 +00:00
|
|
|
void* QThread_Metacast(QThread* self, const char* param1);
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QThread_Tr(const char* s);
|
|
|
|
struct miqt_string* QThread_TrUtf8(const char* s);
|
2024-09-20 22:32:57 +00:00
|
|
|
void* QThread_CurrentThreadId();
|
2024-08-25 04:08:24 +00:00
|
|
|
QThread* QThread_CurrentThread();
|
|
|
|
int QThread_IdealThreadCount();
|
|
|
|
void QThread_YieldCurrentThread();
|
2024-09-18 00:12:02 +00:00
|
|
|
void QThread_SetPriority(QThread* self, int priority);
|
|
|
|
int QThread_Priority(const QThread* self);
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QThread_IsFinished(const QThread* self);
|
|
|
|
bool QThread_IsRunning(const QThread* self);
|
2024-08-25 04:08:24 +00:00
|
|
|
void QThread_RequestInterruption(QThread* self);
|
2024-09-11 05:41:09 +00:00
|
|
|
bool QThread_IsInterruptionRequested(const QThread* self);
|
2024-08-25 04:08:24 +00:00
|
|
|
void QThread_SetStackSize(QThread* self, unsigned int stackSize);
|
2024-09-11 05:41:09 +00:00
|
|
|
unsigned int QThread_StackSize(const QThread* self);
|
2024-08-25 04:08:24 +00:00
|
|
|
void QThread_Exit(QThread* self);
|
2024-09-11 05:41:09 +00:00
|
|
|
QAbstractEventDispatcher* QThread_EventDispatcher(const QThread* self);
|
2024-08-25 04:08:24 +00:00
|
|
|
void QThread_SetEventDispatcher(QThread* self, QAbstractEventDispatcher* eventDispatcher);
|
|
|
|
bool QThread_Event(QThread* self, QEvent* event);
|
2024-09-11 05:41:09 +00:00
|
|
|
int QThread_LoopLevel(const QThread* self);
|
2024-08-29 07:01:51 +00:00
|
|
|
void QThread_Start(QThread* self);
|
2024-08-25 04:08:24 +00:00
|
|
|
void QThread_Terminate(QThread* self);
|
|
|
|
void QThread_Quit(QThread* self);
|
|
|
|
bool QThread_Wait(QThread* self);
|
|
|
|
bool QThread_WaitWithTime(QThread* self, unsigned long time);
|
|
|
|
void QThread_Sleep(unsigned long param1);
|
|
|
|
void QThread_Msleep(unsigned long param1);
|
|
|
|
void QThread_Usleep(unsigned long param1);
|
2024-09-14 22:29:05 +00:00
|
|
|
struct miqt_string* QThread_Tr2(const char* s, const char* c);
|
|
|
|
struct miqt_string* QThread_Tr3(const char* s, const char* c, int n);
|
|
|
|
struct miqt_string* QThread_TrUtf82(const char* s, const char* c);
|
|
|
|
struct miqt_string* QThread_TrUtf83(const char* s, const char* c, int n);
|
2024-08-25 04:08:24 +00:00
|
|
|
void QThread_Exit1(QThread* self, int retcode);
|
2024-09-18 00:12:02 +00:00
|
|
|
void QThread_Start1(QThread* self, int param1);
|
2024-08-25 04:08:24 +00:00
|
|
|
bool QThread_Wait1(QThread* self, QDeadlineTimer* deadline);
|
|
|
|
void QThread_Delete(QThread* self);
|
|
|
|
|
|
|
|
#ifdef __cplusplus
|
|
|
|
} /* extern C */
|
|
|
|
#endif
|
|
|
|
|
|
|
|
#endif
|