mirror of
https://github.com/QuasarApp/Heart.git
synced 2025-04-27 02:04:38 +00:00
fix render loop object
This commit is contained in:
parent
55c80f3e24
commit
299fbe8e40
@ -7,6 +7,7 @@
|
|||||||
|
|
||||||
#include "asyncrenderloop.h"
|
#include "asyncrenderloop.h"
|
||||||
#include <QThread>
|
#include <QThread>
|
||||||
|
#include <qdebug.h>
|
||||||
|
|
||||||
namespace QH {
|
namespace QH {
|
||||||
|
|
||||||
@ -15,6 +16,8 @@ AsyncRenderLoop::AsyncRenderLoop(QThread *thread, QObject *ptr): Async(thread, p
|
|||||||
|
|
||||||
AsyncRenderLoop::~AsyncRenderLoop() {
|
AsyncRenderLoop::~AsyncRenderLoop() {
|
||||||
AsyncRenderLoop::stop();
|
AsyncRenderLoop::stop();
|
||||||
|
delete thread();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void QH::AsyncRenderLoop::run() {
|
void QH::AsyncRenderLoop::run() {
|
||||||
@ -34,6 +37,7 @@ void QH::AsyncRenderLoop::stop() {
|
|||||||
m_run = false;
|
m_run = false;
|
||||||
thread()->quit();
|
thread()->quit();
|
||||||
thread()->wait();
|
thread()->wait();
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
bool AsyncRenderLoop::isRun() const {
|
bool AsyncRenderLoop::isRun() const {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user